1
0
Fork 0

matroskadec_haali: support demuxing QDM2/SVQ3 as written by mkvtoolnix

This commit is contained in:
Hendrik Leppkes 2014-02-13 08:11:16 +01:00
parent 2a5913447c
commit 342a342560
Signed by: hendrik
GPG Key ID: 846079A4B0A7C1B5
1 changed files with 12 additions and 1 deletions

View File

@ -1093,9 +1093,20 @@ static int mkv_read_header(AVFormatContext *s)
if (ret < 0)
return ret;
codec_id = st->codec->codec_id;
} else if (!strcmp(info->CodecID, "A_QUICKTIME") && (info->CodecPrivateSize >= 86) && (info->CodecPrivate != NULL)) {
fourcc = AV_RL32((uint8_t *)info->CodecPrivate + 4);
codec_id = ff_codec_get_id(ff_codec_movaudio_tags, fourcc);
if (ff_codec_get_id(ff_codec_movaudio_tags, AV_RL32((uint8_t *)info->CodecPrivate))) {
fourcc = AV_RL32((uint8_t *)info->CodecPrivate);
codec_id = ff_codec_get_id(ff_codec_movaudio_tags, fourcc);
}
} else if (!strcmp(info->CodecID, "V_QUICKTIME") && (info->CodecPrivateSize >= 86) && (info->CodecPrivate != NULL)) {
fourcc = AV_RL32(info->CodecPrivate);
fourcc = AV_RL32((uint8_t *)info->CodecPrivate + 4);
codec_id = ff_codec_get_id(ff_codec_movvideo_tags, fourcc);
if (ff_codec_get_id(ff_codec_movvideo_tags, AV_RL32((uint8_t *)info->CodecPrivate))) {
fourcc = AV_RL32((uint8_t *)info->CodecPrivate);
codec_id = ff_codec_get_id(ff_codec_movvideo_tags, fourcc);
}
} else if (codec_id == AV_CODEC_ID_PCM_S16BE) {
switch (info->AV.Audio.BitDepth) {
case 8: codec_id = AV_CODEC_ID_PCM_U8; break;