[FFmpeg-devel] [PATCH] avformat/apngenc: use the stream parameters extradata if no updated one is made available

Hendrik Leppkes h.leppkes at gmail.com
Wed Nov 2 22:10:20 EET 2016


On Wed, Nov 2, 2016 at 8:13 PM, Andreas Cadhalpun
<andreas.cadhalpun at googlemail.com> wrote:
> On 01.11.2016 23:10, Hendrik Leppkes wrote:
>> Am 01.11.2016 17:17 schrieb "Andreas Cadhalpun" <
>> andreas.cadhalpun at googlemail.com>:
>>> Not again, but instead, as the extradata is then only transferred as side data.
>>> That way it is again consistent between demuxer/decoder and encoder/muxer.
>>>
>>
>> I don't think thats a good idea. Demuxers should fill the extradata field
>> if any is present and required for decoding - some other decoder might want
>> extradata for init or something, and that way you can accommodate it
>> without having to wait for the first packet.
>
> Is this documented somewhere?

What documented? This seems quite logical. If you have extradata, set
extradata in codecpar

>
>> That's basically how all demuxers work, will extradata and if it can and
>> does change just send an update notice.
>
> Requiring to use codecpar->extradata for passing this from demuxer to decoder,
> while at the same time requiring to use AV_PKT_DATA_NEW_EXTRADATA side data
> to pass this from muxer to encoder seems quite strange to me.
>

encoders should also be able to just set extradata and the muxer read
that, this is how many other encoders work.
I don't know how the apng muxer works, but maybe it also just pretends
to be special.

- Hendrik


More information about the ffmpeg-devel mailing list