[MPlayer-users] Re: cropping & scaling

Jonathan Rogers jonner at teegra.net
Fri Jul 4 22:23:19 CEST 2003


andrea_meroni wrote:
> this is my encoding command:
> 
> mencoder -dvd 1 -ovc frameno -o frameno.avi -oac mp3lame -lameopts  preset=128 -alang it  && mencoder -dvd 1 -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=949:vhq:vpass=1 -vop scale=716:304,crop=716:432:2:70 -oac copy -o /dev/null && mencoder -dvd 1 -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=949:vhq:vpass=2 -vop scale=716:304,crop=716:432:2:70  -oac copy -o they_live.avi
> 
> 
> questions:
> 
> 1. why don't I get the film properly cropped? I mean that after encoding I still see the black bars as in the original dvd (and with the same size)
> 2. are the scale values correct (is it correct to use the crop-x-value to scale?)? or should I use 640:272? Where is the difference?

If the visible part of the original film frame is indeed 716x432, your 
command appears correct. It would be a lot easier to attempt diagnosis 
with mencoder output.

You can scale the output frame to whatever size you wish, regardless of 
the input size. However, it is strongly recommended to use multiples of 
16 for both dimensions. Some codecs break with other sizes, while the 
ones that work may suffer greatly in efficiency. This stems from the 
fact that most (all?) MPEG-like codecs use 16x16 macroblocks. I think 
I've seen a mention of 8x8 macroblocks being possible in MPEG-4, but I 
don't know the details or which particular implementations support it.

Jonathan Rogers



More information about the MPlayer-users mailing list