[MPlayer-dev-eng] [PATCH] dsize negative scale values

Trent Piepho xyzzy at speakeasy.org
Mon Jul 4 09:22:57 CEST 2005


On Sun, 3 Jul 2005, RC wrote:
> 
> How about a compromise between these two?  Why not just add two
> (optional) parameters to my version of the dsize patch...  A max width/
> height value, so eg. "dsize=800:-2:800:600" (or
> dsize=800:-2::600, or dsize=-2:600:800) would work for you, and still be
> very simple and easy for everyone to understand?

How about....

dsize=x:y:aspect_method

x or y = 0, as if you had specified the original size
aspect_method = 0 Preserve aspect, treat x:y as a minimum size (default)
aspect_method = 1 Preserve aspect, treat x:y as a maximum size
apsect_method = 2 Ignore the aspect ratio, just use x:y

If you want to:
Upscale to the correct aspect, dsize=0:0:0
Downscale to the correct aspect, dsize=0:0:1
Fit in 800x600 with the correct aspect, dsize=800:600:1
Just horizontally scale to get the correct aspect, dsize=9999:0:1
Just use 640x480 no matter what, dsize=640:480:2

Is there any reasonable thing that a person would want to do that you can't
easily do this way?




More information about the MPlayer-dev-eng mailing list