[FFmpeg-devel] [PATCH] Parsing ALS object type in MPEG-4

Alex Converse alex.converse
Wed Nov 11 23:17:52 CET 2009


On Wed, Nov 11, 2009 at 5:03 PM, Thilo Borgmann
<thilo.borgmann at googlemail.com> wrote:
> Thilo Borgmann schrieb:
>> Alex Converse schrieb:
>>> On Sun, Oct 11, 2009 at 5:04 AM, Thilo Borgmann
>>> <thilo.borgmann at googlemail.com> wrote:
>>>> Index: libavcodec/mpeg4audio.h
>>>> ===================================================================
>>>> --- libavcodec/mpeg4audio.h ? ? (revision 20011)
>>>> +++ libavcodec/mpeg4audio.h ? ? (working copy)
>>>> @@ -31,6 +31,7 @@
>>>> ? ? int sampling_index;
>>>> ? ? int sample_rate;
>>>> ? ? int chan_config;
>>>> + ? ?int channels;
>>>> ? ? int sbr; //< -1 implicit, 1 presence
>>>> ? ? int ext_object_type;
>>>> ? ? int ext_sampling_index;
>>>> Index: libavformat/mov.c
>>>> ===================================================================
>>>> --- libavformat/mov.c ? (revision 20011)
>>>> +++ libavformat/mov.c ? (working copy)
>>>> @@ -434,9 +434,13 @@
>>>> ? ? ? ? ? ? ? ? MPEG4AudioConfig cfg;
>>>> ? ? ? ? ? ? ? ? ff_mpeg4audio_get_config(&cfg, st->codec->extradata,
>>>> ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?st->codec->extradata_size);
>>>> + ? ? ? ? ? ? ? ?if (cfg.chan_config) {
>>>> ? ? ? ? ? ? ? ? if (cfg.chan_config > 7)
>>>> ? ? ? ? ? ? ? ? ? ? return -1;
>>>> ? ? ? ? ? ? ? ? st->codec->channels = ff_mpeg4audio_channels[cfg.chan_config];
>>>> + ? ? ? ? ? ? ? ?} else {
>>>> + ? ? ? ? ? ? ? ? ? ?st->codec->channels = cfg.channels;
>>>> + ? ? ? ? ? ? ? ?}
>>>> ? ? ? ? ? ? ? ? if (cfg.object_type == 29 && cfg.sampling_index < 3) // old mp3on4
>>>> ? ? ? ? ? ? ? ? ? ? st->codec->sample_rate = ff_mpa_freq_tab[cfg.sampling_index];
>>>> ? ? ? ? ? ? ? ? else
>>>>
>>> These chunks have landed as part of r20512.
>>
>> Yes, thanks for that :)
>>
>
> What remains is handling ALS...
>
> -Thilo
>
> Index: libavcodec/mpeg4audio.c

Applied r20516



More information about the ffmpeg-devel mailing list