]> git.sesse.net Git - ffmpeg/commitdiff
avformat/matroskadec: support SVQ3 as generated by mkvtoolnix-6.6.0
authorMichael Niedermayer <michaelni@gmx.at>
Sun, 19 Jan 2014 17:35:33 +0000 (18:35 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Sun, 19 Jan 2014 17:48:11 +0000 (18:48 +0100)
Fixes part of Ticket3256

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavformat/matroskadec.c

index 299cbd074e1de44692bff257070ee20be2ff67cf..bae98128fd4d35742ee878e5ead3866cff06efd9 100644 (file)
@@ -1725,8 +1725,12 @@ static int matroska_read_header(AVFormatContext *s)
         } else if (!strcmp(track->codec_id, "V_QUICKTIME")
                    && (track->codec_priv.size >= 86)
                    && (track->codec_priv.data != NULL)) {
-            fourcc = AV_RL32(track->codec_priv.data);
+            fourcc = AV_RL32(track->codec_priv.data + 4);
             codec_id = ff_codec_get_id(ff_codec_movvideo_tags, fourcc);
+            if (ff_codec_get_id(ff_codec_movvideo_tags, AV_RL32(track->codec_priv.data))) {
+                fourcc = AV_RL32(track->codec_priv.data);
+                codec_id = ff_codec_get_id(ff_codec_movvideo_tags, fourcc);
+            }
         } else if (codec_id == AV_CODEC_ID_PCM_S16BE) {
             switch (track->audio.bitdepth) {
             case  8:  codec_id = AV_CODEC_ID_PCM_U8;     break;