[FFmpeg-devel] [PATCH]Support more Atrac3-in-mkv samples
Paul B Mahol
onemda at gmail.com
Sun Feb 10 11:21:47 CET 2013
On 2/10/13, Carl Eugen Hoyos <cehoyos at ag.or.at> wrote:
> Hi!
>
> Attached patch allows to decode more atrac3 samples muxed with mkvmerge.
> (For example if KingOfTheJailhouse.rm is used as input file.)
>
> I will commit if nobody objects.
>
> Carl Eugen
>
> diff --git a/libavcodec/atrac3.c b/libavcodec/atrac3.c
> index 1e54784..8d14fad 100644
> --- a/libavcodec/atrac3.c
> +++ b/libavcodec/atrac3.c
> @@ -908,7 +908,8 @@ static av_cold int atrac3_decode_init(AVCodecContext *avctx)
> avctx->channels, frame_factor);
> return AVERROR_INVALIDDATA;
> }
> - } else if (avctx->extradata_size == 10) {
> + } else if (avctx->extradata_size == 12 ||
> + avctx->extradata_size == 10) {
> /* Parse the extradata, RM format. */
> version = bytestream_get_be32(&edata_ptr);
> samples_per_frame = bytestream_get_be16(&edata_ptr);
What extra 2 bytes have? The matroska spec mentions 2 version of
headers and matroska demuxer skips first 22 bytes.
LGTM anyway.
More information about the ffmpeg-devel
mailing list