changeset 3877:a3c73266f81f

fixed rv10 with subid=3
author alex
date Sat, 29 Dec 2001 16:42:50 +0000
parents d619260dc756
children 1db1b532cdd2
files dec_video.c libmpdemux/demux_real.c
diffstat 2 files changed, 7 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/dec_video.c	Sat Dec 29 11:35:21 2001 +0000
+++ b/dec_video.c	Sat Dec 29 16:42:50 2001 +0000
@@ -483,6 +483,8 @@
     lavc_context.width=sh_video->disp_w;
     lavc_context.height=sh_video->disp_h;
     mp_dbg(MSGT_DECVIDEO,MSGL_DBG2,"libavcodec.size: %d x %d\n",lavc_context.width,lavc_context.height);
+    if (sh_video->format == mmioFOURCC('R', 'V', '1', '3'))
+	lavc_context.sub_id = 3;
     /* open it */
     if (avcodec_open(&lavc_context, lavc_codec) < 0) {
         mp_msg(MSGT_DECVIDEO,MSGL_ERR, MSGTR_CantOpenCodec);
--- a/libmpdemux/demux_real.c	Sat Dec 29 11:35:21 2001 +0000
+++ b/libmpdemux/demux_real.c	Sat Dec 29 16:42:50 2001 +0000
@@ -147,8 +147,8 @@
     /* flags:		*/
     /* 	0x2 - keyframe	*/
 
-    printf("packet#%d: len: %d, stream_id: %d, timestamp: %d, flags: %x\n",
-	priv->num_of_packets, len, stream_id, timestamp, flags);
+//    printf("packet#%d: len: %d, stream_id: %d, timestamp: %d, flags: %x\n",
+//	priv->num_of_packets, len, stream_id, timestamp, flags);
 
     priv->num_of_packets--;
     len -= 12;    
@@ -352,6 +352,8 @@
 		    sh->samplerate = stream_read_word(demuxer->stream);
 		    stream_skip(demuxer->stream, 4);
 		    sh->channels = stream_read_word(demuxer->stream);
+		    printf("samplerate: %d, channels: %d\n",
+			sh->samplerate, sh->channels);
 		
 		    /* Desc #1 */
 		    skip_str(1, demuxer);
@@ -453,6 +455,7 @@
 			case 0x10003001:
 			    /* sub id: 3 */
 			    /* codec id: rv10 */
+			    sh->bih->biCompression = sh->format = mmioFOURCC('R', 'V', '1', '3');
 			    break;
 			case 0x20001000:
 			case 0x20100001: