[Mplayer-cvslog] CVS: main/libmpcodecs img_format.c,1.3,1.4 img_format.h,1.6,1.7 mp_image.h,1.13,1.14
Michael Niedermayer
michael at mplayerhq.hu
Thu Jun 27 19:35:40 CEST 2002
Update of /cvsroot/mplayer/main/libmpcodecs
In directory mail:/var/tmp.root/cvs-serv17727
Modified Files:
img_format.c img_format.h mp_image.h
Log Message:
{RGB,BGR}{1,4}
Index: img_format.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/img_format.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- img_format.c 22 Jun 2002 08:47:56 -0000 1.3
+++ img_format.c 27 Jun 2002 17:35:37 -0000 1.4
@@ -4,11 +4,15 @@
{
switch(format)
{
+ case IMGFMT_RGB1: return("RGB 1-bit");
+ case IMGFMT_RGB4: return("RGB 4-bit");
case IMGFMT_RGB8: return("RGB 8-bit");
case IMGFMT_RGB15: return("RGB 15-bit");
case IMGFMT_RGB16: return("RGB 16-bit");
case IMGFMT_RGB24: return("RGB 24-bit");
case IMGFMT_RGB32: return("RGB 32-bit");
+ case IMGFMT_BGR1: return("BGR 1-bit");
+ case IMGFMT_BGR4: return("BGR 4-bit");
case IMGFMT_BGR8: return("BGR 8-bit");
case IMGFMT_BGR15: return("BGR 15-bit");
case IMGFMT_BGR16: return("BGR 16-bit");
Index: img_format.h
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/img_format.h,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- img_format.h 22 Jun 2002 08:47:56 -0000 1.6
+++ img_format.h 27 Jun 2002 17:35:37 -0000 1.7
@@ -6,6 +6,8 @@
#define IMGFMT_RGB_MASK 0xFFFFFF00
#define IMGFMT_RGB (('R'<<24)|('G'<<16)|('B'<<8))
+#define IMGFMT_RGB1 (IMGFMT_RGB|1)
+#define IMGFMT_RGB4 (IMGFMT_RGB|4)
#define IMGFMT_RGB8 (IMGFMT_RGB|8)
#define IMGFMT_RGB15 (IMGFMT_RGB|15)
#define IMGFMT_RGB16 (IMGFMT_RGB|16)
@@ -14,6 +16,8 @@
#define IMGFMT_BGR_MASK 0xFFFFFF00
#define IMGFMT_BGR (('B'<<24)|('G'<<16)|('R'<<8))
+#define IMGFMT_BGR1 (IMGFMT_BGR|1)
+#define IMGFMT_BGR4 (IMGFMT_BGR|4)
#define IMGFMT_BGR8 (IMGFMT_BGR|8)
#define IMGFMT_BGR15 (IMGFMT_BGR|15)
#define IMGFMT_BGR16 (IMGFMT_BGR|16)
Index: mp_image.h
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/mp_image.h,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- mp_image.h 23 Jun 2002 21:08:31 -0000 1.13
+++ mp_image.h 27 Jun 2002 17:35:37 -0000 1.14
@@ -73,11 +73,13 @@
mpi->num_planes=1;
if( (out_fmt&IMGFMT_RGB_MASK) == IMGFMT_RGB ){
mpi->bpp=((out_fmt&255)+7)&(~7);
+ if(out_fmt==IMGFMT_RGB1) mpi->bpp=1;
return;
}
if( (out_fmt&IMGFMT_BGR_MASK) == IMGFMT_BGR ){
mpi->bpp=((out_fmt&255)+7)&(~7);
mpi->flags|=MP_IMGFLAG_SWAPPED;
+ if(out_fmt==IMGFMT_BGR1) mpi->bpp=1;
return;
}
mpi->flags|=MP_IMGFLAG_YUV;
More information about the MPlayer-cvslog
mailing list