Skip to content

core: rework vlc_ancillary API

Thomas Guillem requested to merge tguillem/vlc:ancillary_list into master

Add a new API: vlc_ancillary_list, a vlc_list + refcount + mutex that hold all ancillaries.

The previous API: vlc_ancillary is now only used internally and not exported.

The main reason for this rework is to allow passing all ancillaries from block/frames to pictures and vice versa in a more convenient way. The user doesn't have to enumerate all ancillaries ID explicitly, and can now pass ancillaries that are unknown to the current module. Indeed, an ancillary created by a demux could be unknown to a packetizer but handled by a decoder module, for example.

Some decoder modules allow passing extra data (reorder_opaque in ffmpeg, sourceFrameRefCon in videotoolbox). Passing and holding a vlc_ancillary_list might be more convenient than passing and holding the whole input data (vlc_frame_t).

This is needed for the clock-context !5144 that will use ancillary data. An intermediate MR will be needed to actually pass ancillaries from all packetizers and codecs modules. Once this work is done, any extra data can be passed from the demux to the outpit.

Merge request reports