[MPlayer-cvslog] CVS: main/libvo vo_fbdev.c, 1.93, 1.94 vo_fbdev2.c, 1.8, 1.9
Alan Curry CVS
syncmail at mplayerhq.hu
Sat Mar 4 21:00:09 CET 2006
CVS change done by Alan Curry CVS
Update of /cvsroot/mplayer/main/libvo
In directory mail:/var2/tmp/cvs-serv19153/libvo
Modified Files:
vo_fbdev.c vo_fbdev2.c
Log Message:
When centering a video with odd width, be sure to start on a pixel boundary.
Index: vo_fbdev.c
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/vo_fbdev.c,v
retrieving revision 1.93
retrieving revision 1.94
diff -u -r1.93 -r1.94
--- vo_fbdev.c 17 Feb 2006 03:49:33 -0000 1.93
+++ vo_fbdev.c 4 Mar 2006 20:00:06 -0000 1.94
@@ -1005,8 +1005,9 @@
return 1;
}
- center = frame_buffer + (out_width - in_width) * fb_pixel_size /
- 2 + ( (out_height - in_height) / 2 ) * fb_line_len +
+ center = frame_buffer +
+ ( (out_width - in_width) / 2 ) * fb_pixel_size +
+ ( (out_height - in_height) / 2 ) * fb_line_len +
x_offset * fb_pixel_size + y_offset * fb_line_len;
mp_msg(MSGT_VO, MSGL_DBG2, "frame_buffer @ %p\n", frame_buffer);
Index: vo_fbdev2.c
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/vo_fbdev2.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- vo_fbdev2.c 17 Feb 2006 03:49:33 -0000 1.8
+++ vo_fbdev2.c 4 Mar 2006 20:00:06 -0000 1.9
@@ -280,8 +280,9 @@
}
}
- center = frame_buffer + (out_width - in_width) * fb_pixel_size /
- 2 + ( (out_height - in_height) / 2 ) * fb_line_len;
+ center = frame_buffer +
+ ( (out_width - in_width) / 2 ) * fb_pixel_size +
+ ( (out_height - in_height) / 2 ) * fb_line_len;
#ifndef USE_CONVERT2FB
if (!(next_frame = (uint8_t *) realloc(next_frame, in_width * in_height * fb_pixel_size))) {
More information about the MPlayer-cvslog
mailing list