[MPlayer-dev-eng] Error in docs? (Preserving aspect ratio)

Diego Biurrun diego at biurrun.de
Fri Apr 25 09:40:02 CEST 2003


Jason Tackaberry writes:
 > http://mplayerhq.hu/DOCS/encoding.html rightly suggests to crop out
 > black bars in the original movie source when encoding.  It then goes on
 > to suggest that you should preserve the aspect ratio if you use
 > libavcodec.  Both excellent practices, which I follow.
 > 
 > But as I was reading these docs, I noticed a problem in the proposed
 > command line:
 > 
 > $ mencoder sample-svcd.mpg -ovc lavc -lavcopts vcodec=mpeg4:aspect=16.0/9.0 -vop crop=714:548:0:14 -oac copy -o output.avi
 > 
 > Now either there is a problem here, or I am misunderstanding something
 > and as a result have messed up all my encodings. :)
 > 
 > The problem, as I understand things, is that if you specify a crop
 > region, you must also adjust the aspect ratio for the new size.   The
 > cropped region above is no longer 16/9.
 > 
 > For a 16/9 DVD, the video source is usually 720x480 which gets scaled to
 > 854x480.  So the correct aspect ratio for the above cropped video, where
 > the original is 16/9, is 714*(854/720)/548, or 1.545.  The libavcodec
 > option should then be aspect=1.545.
 > 
 > Although I think I have a handle on this, and I think the docs are
 > wrong, please do let me know if I'm misguided. :)

I'll change it after the weekend.  Thanks for pointing this out.
Regards

Diego



More information about the MPlayer-dev-eng mailing list