[MPlayer-cvslog] CVS: main/libmpcodecs vf_expand.c,1.33,1.34

Oded Shimon CVS syncmail at mplayerhq.hu
Mon Dec 5 18:52:02 CET 2005


CVS change done by Oded Shimon CVS

Update of /cvsroot/mplayer/main/libmpcodecs
In directory mail:/var2/tmp/cvs-serv2949/libmpcodecs

Modified Files:
	vf_expand.c 
Log Message:
expand aspect works by display aspect, not video aspect.
try 2


Index: vf_expand.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf_expand.c,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -r1.33 -r1.34
--- vf_expand.c	18 Nov 2005 14:39:23 -0000	1.33
+++ vf_expand.c	5 Dec 2005 17:52:00 -0000	1.34
@@ -183,10 +183,11 @@
         else if( vf->priv->exp_h<height ) vf->priv->exp_h=height;
 #endif
     if (vf->priv->aspect) {
+        vf->priv->aspect *= ((double)width/height) / ((double)d_width/d_height);
         if (vf->priv->exp_h < vf->priv->exp_w / vf->priv->aspect) {
-            vf->priv->exp_h = vf->priv->exp_w / vf->priv->aspect;
+            vf->priv->exp_h = vf->priv->exp_w / vf->priv->aspect + 0.5;
         } else {
-            vf->priv->exp_w = vf->priv->exp_h * vf->priv->aspect;
+            vf->priv->exp_w = vf->priv->exp_h * vf->priv->aspect + 0.5;
         }
     }
     if (vf->priv->round > 1) { // round up.




More information about the MPlayer-cvslog mailing list