[MPlayer-users] I wrote a mencoder mini-guide for DVD ripping

D Richard Felker III dalias at aerifal.cx
Fri Aug 23 16:52:01 CEST 2002


On Thu, Aug 22, 2002 at 12:27:39AM +0200, Nico wrote:
> 3. if the movie has black borders you can take them off. First, calculate
> the borders geometry
>    whith option cropdetect:
> 
>        mencoder -aspect 16:9 -dvd 10 -ovc lavc -lavcopts
>        vcodec=mpeg4:vhq:vbitrate=694 -vop cropdetect,scale -zoom -xy
>        640  -oac mp3lame -lameopts br=128:vol=9 -o tigreydragon.avi
> 
>    let it run for a while to make sure is ripping the real movie (and
>    not just the credits)
>    and you'll get the values you have to pass to crop option to take
>    the black borders off
>    (i.e. in Crouching Tiger.. I get crop=640:272:0:44). Keep in mind
>    these values are relative
>    to the output resolution.

Encoding will be much faster if you crop *before* scaling! I'm not
sure if mencoder will get the aspect stuff right automagically if you
do it in this order though, but...

>         vbitrate=694 in -lavcopts (video rate i got with my script
>         dvd-ripping)

This bitrate is probably way too low for 640x272 if you want decent
quality, so you should probably scale down to 512x216 or so. Also keep
in mind that keeping both width and height a multiple of 8 (or better
yet 16, for chroma macroblocks) is important for preventing wasted
bits.

You might also mention that even a slight black border can waste a LOT
of bits, so it's better to slightly overcrop than undercrop.

Otherwise looks good.

Rich




More information about the MPlayer-users mailing list