LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Mencoder yields 2GB output without crop, 2MB output with crop (https://www.linuxquestions.org/questions/linux-software-2/mencoder-yields-2gb-output-without-crop-2mb-output-with-crop-923095/)

porphyry5 01-10-2012 12:22 PM

Mencoder yields 2GB output without crop, 2MB output with crop
 
Does anyone know offhand if mencoder's crop feature clashes with any of its other options? I'm using a direct adaptation of
http://www.mplayerhq.hu/DOCS/HTML/en...t-vcd-dvd.html
Section 7.8.5.1.

Without the crop option, I get the desired output file of ~2GB. When I add the crop option, encoding finishes in about a minute, producing a 2MB file. These are the two commands, identical in every respect except for the crop, whose parameters I got via -cropdetect
Code:

mencoder dvd://1 -dvd-device VIDEO_TS -oac lavc -ovc lavc -of mpeg -nosub \
-mpegopts format=dvd:tsaf -vf crop=688:432:18:72,harddup -srate 48000 -af lavcresample=48000 \
-lavcopts vcodec=mpeg2video:vrc_buf_size=1835:vrc_maxrate=6424:vbitrate=2400:\
keyint=15:vstrict=0:acodec=ac3:abitrate=192:aspect=16/9:vpass=1 -ofps 25 -o movie.1

mencoder dvd://1 -dvd-device VIDEO_TS -oac lavc -ovc lavc -of mpeg -nosub \
-mpegopts format=dvd:tsaf -vf harddup -srate 48000 -af lavcresample=48000 \
-lavcopts vcodec=mpeg2video:vrc_buf_size=1835:vrc_maxrate=6424:vbitrate=2400:\
keyint=15:vstrict=0:acodec=ac3:abitrate=192:aspect=16/9:vpass=1 -ofps 25 -o movie.1

grep CROP log.txt | tail -1
[CROP] Crop area: X: 9..712  Y: 71..504  (-vf crop=688:432:18:72).


acid_kewpie 01-11-2012 04:54 AM

use the vf filter to watch the video with mplayer, that'll probably shed some light on it, although extra degbugging on the menocder command should also be a lot of use.

porphyry5 01-11-2012 06:44 AM

Quote:

Originally Posted by acid_kewpie (Post 4571718)
use the vf filter to watch the video with mplayer, that'll probably shed some light on it, although extra degbugging on the menocder command should also be a lot of use.

Thanks, that's what I was afraid of, going to have to dig for this one. But it was worth a try.

Watching the movie with the vf filter appeared completely normal, so I started trying elimination to find the problem, and struck gold on the first try. For some unknown reason "crop" and "harddup" clash. When I removed "harddup" all was well.

The manual states "harddup" is necessary for mpeg output, and as it prevents mencoder dropping frames I expected to find the video and audio out of sync by the end of the movie. But there was no sign of that at all, nor any other adverse effect that I noticed.


All times are GMT -5. The time now is 04:26 PM.