[FFmpeg-devel] [RFC] stream parsing

Alex Converse alex.converse
Tue Sep 28 05:50:14 CEST 2010


On Sun, Sep 26, 2010 at 5:14 AM, Michael Niedermayer <michaelni at gmx.at> wrote:
> On Sun, Sep 26, 2010 at 12:54:34PM +0200, Benjamin Larsson wrote:
>>
>> >
>> > this looks strange
>> > i would have expected a
>> > if((codec->capabilities & CODEC_CAP_CHANNEL_CONF) && !channel_layout)
>> > ? ? return 0;
>> >
>> > in has_codec_parameters()
>>
>>
>> There is no AVCodec available in has_codec_parameters() only an
>> AVCodecContext.
>
> AVCodecContext.codec
>
>
>>
>> >
>> > but maybe this doesnt work for some case?
>>
>> It wont work as it's the wrong struct.
>>
>>
>> >
>> > at least your "if we dont have all parameters remove these 3 parameters"
>> > is looking worse
>> >
>>
>> This is what the AAC codec uses, I'm not saying its correct I just took
>> something that worked. But IIRC something need to set these to 0 before
>> opening the decoder otherwise it will use the values the demuxer set.
>
> the decoder should override them if they are wrong
> for AAC there maybe are further considerations due to SBR
>

The issues for AAC stem from implicit SBR, implicit PS, and late
implicit PS. Faad takes a guess based on channel count and sample if
there is no signalling information. that might actually be cleaner. In
that case the encoder should be made to signal the absence of SBR with
backward compatible signalling.

[...]



More information about the ffmpeg-devel mailing list