[Mplayer-cvslog] CVS: main/libmpdemux demux_nsv.c,1.5,1.6

Roberto Togni CVS syncmail at mplayerhq.hu
Sun Apr 25 15:40:55 CEST 2004


CVS change done by Roberto Togni CVS

Update of /cvsroot/mplayer/main/libmpdemux
In directory mail:/var2/tmp/cvs-serv2967

Modified Files:
	demux_nsv.c 
Log Message:
Fix VP62 keyframe search
Fixed by Reza Jelveh


Index: demux_nsv.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_nsv.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- demux_nsv.c	25 Apr 2004 01:51:53 -0000	1.5
+++ demux_nsv.c	25 Apr 2004 13:40:53 -0000	1.6
@@ -259,15 +259,16 @@
             sh_video->bih->biSizeImage=sh_video->bih->biWidth*sh_video->bih->biHeight*3;
 
             // here we search for the correct keyframe 
-            // vp6 keyframe is when the 2nd byte of the vp6 header is 0x36
+            // vp6 keyframe is when the 2nd byte of the vp6 header is
+            // 0x36 for VP61 and 0x46 for VP62
             if((priv->v_format==mmioFOURCC('V','P','6','1')) ||
                (priv->v_format==mmioFOURCC('V','P','6','2')) ||
                (priv->v_format==mmioFOURCC('V','P','3','1'))) {
                 stream_read(demuxer->stream,buf,10);
-                if (((((priv->v_format>>16) & 0xff) == '6') && (buf[8]!=0x36)) ||
+                if (((((priv->v_format>>16) & 0xff) == '6') && ((buf[8]&0x0f)!=0x06)) ||
                     ((((priv->v_format>>16) & 0xff) == '3') && (buf[8]!=0x00 || buf[9]!=0x08))) {
                     mp_msg(MSGT_DEMUX,MSGL_V,"demux_nsv: searching %.4s keyframe...\n", (char*)&priv->v_format);
-                    while(((((priv->v_format>>16) & 0xff) == '6') && (buf[8]!=0x36)) ||
+                    while(((((priv->v_format>>16) & 0xff) == '6') && ((buf[8]&0x0f)!=0x06)) ||
                           ((((priv->v_format>>16) & 0xff) == '3') && (buf[8]!=0x00 || buf[9]!=0x08))){
                         mp_msg(MSGT_DEMUX,MSGL_DBG2,"demux_nsv: %.4s block skip.\n", (char*)&priv->v_format);
                         videolen=(buf[2]>>4)|(buf[3]<<4)|(buf[4]<<0xC);




More information about the MPlayer-cvslog mailing list