8 Dec 2021, 02:06 by [email protected]: > From: Anton Khirnov <[email protected]> > > The new API is more extensible and allows for custom layouts. > More accurate information is exported, eg for decoders that do not > set a channel layout, lavc will not make one up for them. > > Deprecate the old API working with just uint64_t bitmasks. > > Expanded and completed by Vittorio Giovara <[email protected]> > and James Almer <[email protected]>. > Signed-off-by: Vittorio Giovara <[email protected]> > Signed-off-by: James Almer <[email protected]> > --- > libavutil/channel_layout.c | 498 ++++++++++++++++++++++++++++++------ > libavutil/channel_layout.h | 510 ++++++++++++++++++++++++++++++++++--- > libavutil/version.h | 1 + > 3 files changed, 906 insertions(+), 103 deletions(-) > > /** > * @} > @@ -128,6 +199,157 @@ enum AVMatrixEncoding { > AV_MATRIX_ENCODING_NB > }; > > +/** > + * @} > + */ > + > +/** > + * An AVChannelCustom defines a single channel within a custom order layout > + * > + * Unlike most structures in FFmpeg, sizeof(AVChannelCustom) is a part of the > + * public ABI. > + * > + * No new fields may be added to it without a major version bump. > + */ > +typedef struct AVChannelCustom { > + enum AVChannel id; > +} AVChannelCustom; >
Consider adding a 25-byte or so of a description field string here that would also be copied if the frame/layout is copied? That way, users can assign a description label to each channel, for example labeling each channel in a 255 channel custom layout Opus stream used in production at a venue somewhere. Also, consider additionally reserving 16-bytes here, just in case. Rest looks fine. _______________________________________________ ffmpeg-devel mailing list [email protected] https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email [email protected] with subject "unsubscribe".
