[Mplayer-cvslog] CVS: main/postproc yuv2rgb.c,1.21,1.22

Alex Beregszaszi alex at mplayerhq.hu
Sat Dec 27 20:55:01 CET 2003


Update of /cvsroot/mplayer/main/postproc
In directory mail:/tmp/cvs-serv29689

Modified Files:
	yuv2rgb.c 
Log Message:
correct C init tables

Index: yuv2rgb.c
===================================================================
RCS file: /cvsroot/mplayer/main/postproc/yuv2rgb.c,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -r1.21 -r1.22
--- yuv2rgb.c	1 May 2003 19:14:27 -0000	1.21
+++ yuv2rgb.c	27 Dec 2003 19:54:59 -0000	1.22
@@ -642,8 +642,8 @@
 
 int yuv2rgb_c_init_tables (SwsContext *c, const int inv_table[4], int fullRange, int brightness, int contrast, int saturation)
 {  
-    const int bpp= c->dstFormat&0xFF;
-    const int isRgb= (c->dstFormat>>24) != 'R';
+    const int isRgb = IMGFMT_IS_RGB(c->dstFormat);
+    const int bpp = isRgb?IMGFMT_RGB_DEPTH(c->dstFormat):IMGFMT_BGR_DEPTH(c->dstFormat);
     int i;
     uint8_t table_Y[1024];
     uint32_t *table_32 = 0;




More information about the MPlayer-cvslog mailing list