[Mplayer-cvslog] CVS: main/libmpdemux aviheader.c,1.41,1.42

Arpi of Ize arpi at mplayer.dev.hu
Sun Mar 31 11:50:19 CEST 2002


Update of /cvsroot/mplayer/main/libmpdemux
In directory mplayer:/var/tmp.root/cvs-serv17291

Modified Files:
	aviheader.c 
Log Message:
I hate M$. it seems that MSRLE biSize is always 40 when number of colors < 256 instead of 40+colors*4

Index: aviheader.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/aviheader.c,v
retrieving revision 1.41
retrieving revision 1.42
diff -u -r1.41 -r1.42
--- aviheader.c	12 Feb 2002 01:20:59 -0000	1.41
+++ aviheader.c	31 Mar 2002 09:50:17 -0000	1.42
@@ -176,6 +176,9 @@
         mp_msg(MSGT_HEADER,MSGL_V,"found 'bih', %d bytes of %d\n",chunksize,sizeof(BITMAPINFOHEADER));
         stream_read(demuxer->stream,(char*) sh_video->bih,chunksize);
 	le2me_BITMAPINFOHEADER(sh_video->bih);  // swap to machine endian
+	// fixup MS-RLE header (seems to be broken for <256 color files)
+	if(sh_video->bih->biCompression==1 && sh_video->bih->biSize==40)
+	    sh_video->bih->biSize=chunksize;
         if(verbose>=1) print_video_header(sh_video->bih);
         chunksize=0;
 //        sh_video->fps=(float)sh_video->video.dwRate/(float)sh_video->video.dwScale;




More information about the MPlayer-cvslog mailing list