Log in

View Full Version : Mencoder command problem!


The Shemeta
11th December 2003, 13:36
Hi guys,

i want to test mencoder , but i don't know what i do wrong. when the input is only one file, then it's all good. but when i want to use more files , like more *.vob, i get this error. maybe you know what i am doing wrong.i cd to the directory where my files are & then run:

bash-2.05b$ cat *.vob |mencoder -ovc xvid -xvidencopts pass=1:vhq=1:qpel:chroma_me:max_bframes=2:bquant_ratio=150:bquant_offset=75:bf_threshold=0 -sws 9 -vf crop=720:436:0:74,scale=640:272 -o movie.avi
MEncoder 1.0pre3-3.2.3 (C) 2000-2003 MPlayer Team

CPU: Intel Celeron 2/Pentium III Tualatin 682.9 MHz (Family: 6, Stepping: 1)
Detected cache-line size is 32 bytes
CPUflags: Type: 6 MMX: 1 MMX2: 1 3DNow: 0 3DNow2: 0 SSE: 1 SSE2: 0
Compiled for x86 CPU with extensions: MMX MMX2 SSE

Reading /home/stanislav/.mplayer/codecs.conf: Can't open '/home/stanislav/.mplayer/codecs.conf': No such file or directory
Reading /usr/local/etc/mplayer/codecs.conf: Can't open '/usr/local/etc/mplayer/codecs.conf': No such file or directory
Using built-in default codecs.conf.
File not found: 'frameno.avi'
Failed to open frameno.avi
Reading config file /home/stanislav/.mplayer/mencoder: No such file or directoryNo file given
Exiting... (error parsing cmdline)

thanks for your help! see ya!

doug_s
11th December 2003, 14:41
Try it this way, using the "-" on the end for standard input

cat *.vob | mencoder -ovc xvid -xvidencopts pass=1:vhq=1:qpel:chroma_me:max_bframes=2:bquant_ratio=150:bquant_offset=75:bf_threshold=0
-sws 9 -vf crop=720:436:0:74,scale=640:272 -o movie.avi -

It does work with your vobs concatenated, I did it yesterday.

The Shemeta
11th December 2003, 17:36
well still not working. maybe i am writing the "cat" wrong. that's the first time i am using it, so i don't know how to use it.

do you have any ideas?

doug_s
12th December 2003, 03:45
I did a cut and paste of your command against my own vobs adding the - at the end.

First it gave an error message saying no sound codec was selected, so I added -nosound (you probably want to use an audio codec when doing it for real).

Then it gave a cropping error cause my ntsc dvd is 720x480 and your command would have reached out to position 510 which is out of range. If you're using a pal dvd this may not apply, I don't know the values for pal.

This line really worked on my box:

cat *.vob | mencoder -ovc xvid -xvidencopts pass=1:vhq=1:qpel:chroma_me:max_bframes=2:bquant_ratio=150:bquant_offset=75:bf_threshold=0 -sws 9 -vf crop=710:436:5:32,scale=640:272 -o movie.avi - -nosound

Just pay careful attention to the error messages and you should be able to figure out what's going on.

The Shemeta
12th December 2003, 12:07
yeah, my source was PAL, & i still get this error. is there a way to check what it means, like a log file or something.

& there something else. when i did cat *.vob > file.vob to make one big vob file, i got an error at the 2GB & the program stopped. the files are on FAT32 system. does that have anything to do with the error i get?

juicemansam
13th December 2003, 05:01
I use vstrip to pipe the video stream to mencoder, of course you'll have to change it to your needs. Here's my generic script:

# start encode script
BITRATE=996

vstrip @vts.lst -\!o/dev/stdout 0xe0 | mencoder -nosound \
-vop crop=384:222:0:33,scale=384:288 -sws 9 -noskip -ofps 29.97 -ovc xvid \
-xvidencopts pass=1:bitrate=$BITRATE:me_quality=6 -passlogfile movie.log \
-o movie.avi -

rm -f movie.avi

vstrip @vts.lst -\!o/dev/stdout 0xe0 | mencoder -nosound \
-vop crop=384:222:0:33,scale=384:288 -sws 9 -noskip -ofps 29.97 -ovc xvid \
-xvidencopts pass=2:bitrate=$BITRATE:me_quality=6 -passlogfile movie.log \
-o movie.avi -
# end encode script

TactX
13th December 2003, 13:36
Originally posted by The Shemeta
& there something else. when i did cat *.vob > file.vob to make one big vob file, i got an error at the 2GB & the program stopped. the files are on FAT32 system. does that have anything to do with the error i get?
Yes, FAT32 does only support files < 2GB.

EDIT: FAT32 DOES support files as large as 4GB, but on Linux the maximum filesize is 2GB on FAT32 (depends on the Linux VFAT driver I think)