[MPlayer-cvslog] r36292 - trunk/libvo/vo_gl.c

reimar subversion at mplayerhq.hu
Tue May 28 22:43:51 CEST 2013


Author: reimar
Date: Tue May 28 22:43:50 2013
New Revision: 36292

Log:
Fix border-pos handling.

Modified:
   trunk/libvo/vo_gl.c

Modified: trunk/libvo/vo_gl.c
==============================================================================
--- trunk/libvo/vo_gl.c	Mon May 27 22:36:58 2013	(r36291)
+++ trunk/libvo/vo_gl.c	Tue May 28 22:43:50 2013	(r36292)
@@ -225,10 +225,12 @@ static void resize(void) {
     scale_y = (double)new_h / (double)vo_dheight;
     video_matrix[0]  *= scale_x;
     video_matrix[4]  *= scale_x;
-    video_matrix[12] = -1 + apply_border_pos(vo_dwidth, new_w, vo_border_pos_x) * 2.0 / vo_dwidth;
+    video_matrix[12] *= scale_x;
+    video_matrix[12] += (apply_border_pos(vo_dwidth, new_w, vo_border_pos_x) - apply_border_pos(vo_dwidth, new_w, 0.5)) * 2.0 / vo_dwidth;
     video_matrix[1]  *= scale_y;
     video_matrix[5]  *= scale_y;
-    video_matrix[13] = 1 - apply_border_pos(vo_dheight, new_h, vo_border_pos_y) * 2.0 / vo_dheight;
+    video_matrix[13] *= scale_y;
+    video_matrix[13] -= (apply_border_pos(vo_dheight, new_h, vo_border_pos_y) - apply_border_pos(vo_dheight, new_h, 0.5)) * 2.0 / vo_dheight;
     if (vo_rotate & 1) {
       int tmp = new_w; new_w = new_h; new_h = tmp;
     }


More information about the MPlayer-cvslog mailing list