[Mplayer-cvslog] CVS: main/libvo vo_xv.c,1.45,1.46

Alex Beregszaszi alex at mplayer.dev.hu
Sat Jan 26 16:47:00 CET 2002


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

Modified Files:
	vo_xv.c 
Log Message:
fixed i420 handling

Index: vo_xv.c
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/vo_xv.c,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -r1.45 -r1.46
--- vo_xv.c	23 Jan 2002 17:03:15 -0000	1.45
+++ vo_xv.c	26 Jan 2002 15:46:58 -0000	1.46
@@ -565,8 +565,16 @@
 
      // YV12 planar
      memcpy(xvimage[current_buf]->data,src[0],image_width*image_height);
-     memcpy(xvimage[current_buf]->data+image_width*image_height,src[2],image_width*image_height/4);
-     memcpy(xvimage[current_buf]->data+image_width*image_height*5/4,src[1],image_width*image_height/4);
+     if (xv_format == IMGFMT_YV12)
+     {
+        memcpy(xvimage[current_buf]->data+image_width*image_height,src[2],image_width*image_height/4);
+        memcpy(xvimage[current_buf]->data+image_width*image_height*5/4,src[1],image_width*image_height/4);
+     }
+     else
+     {
+        memcpy(xvimage[current_buf]->data+image_width*image_height,src[1],image_width*image_height/4);
+        memcpy(xvimage[current_buf]->data+image_width*image_height*5/4,src[2],image_width*image_height/4);
+     }
      break;
  }
 




More information about the MPlayer-cvslog mailing list