[Mplayer-cvslog] CVS: main/libvo vo_xv.c,1.91,1.92

Arpi of Ize arpi at mplayerhq.hu
Tue Jun 4 00:29:52 CEST 2002


Update of /cvsroot/mplayer/main/libvo
In directory mail:/var/tmp.root/cvs-serv14442

Modified Files:
	vo_xv.c 
Log Message:
use offsets/pitches for OSD too


Index: vo_xv.c
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/vo_xv.c,v
retrieving revision 1.91
retrieving revision 1.92
diff -u -r1.91 -r1.92
--- vo_xv.c	31 May 2002 21:51:20 -0000	1.91
+++ vo_xv.c	3 Jun 2002 22:29:49 -0000	1.92
@@ -101,15 +101,21 @@
 static void (*draw_alpha_fnc)(int x0,int y0, int w,int h, unsigned char* src, unsigned char *srca, int stride);
 
 static void draw_alpha_yv12(int x0,int y0, int w,int h, unsigned char* src, unsigned char *srca, int stride){
-   vo_draw_alpha_yv12(w,h,src,srca,stride,xvimage[current_buf]->data+image_width*y0+x0,image_width);
+   vo_draw_alpha_yv12(w,h,src,srca,stride,
+       xvimage[current_buf]->data+xvimage[current_buf]->offsets[0]+
+       xvimage[current_buf]->pitches[0]*y0+x0,xvimage[current_buf]->pitches[0]);
 }
 
 static void draw_alpha_yuy2(int x0,int y0, int w,int h, unsigned char* src, unsigned char *srca, int stride){
-   vo_draw_alpha_yuy2(w,h,src,srca,stride,xvimage[current_buf]->data+2*(image_width*y0+x0),2*image_width);
+   vo_draw_alpha_yuy2(w,h,src,srca,stride,
+       xvimage[current_buf]->data+xvimage[current_buf]->offsets[0]+
+       xvimage[current_buf]->pitches[0]*y0+2*x0,xvimage[current_buf]->pitches[0]);
 }
 
 static void draw_alpha_uyvy(int x0,int y0, int w,int h, unsigned char* src, unsigned char *srca, int stride){
-   vo_draw_alpha_yuy2(w,h,src,srca,stride,xvimage[current_buf]->data+2*(image_width*y0+x0)+1,2*image_width);
+   vo_draw_alpha_yuy2(w,h,src,srca,stride,
+       xvimage[current_buf]->data+xvimage[current_buf]->offsets[0]+
+       xvimage[current_buf]->pitches[0]*y0+2*x0+1,xvimage[current_buf]->pitches[0]);
 }
 
 static void draw_alpha_null(int x0,int y0, int w,int h, unsigned char* src, unsigned char *srca, int stride){




More information about the MPlayer-cvslog mailing list