[FFmpeg-devel] [PATCH v10 1/6] lavu/frame: Add Dolby Vision metadata side data type

Niklas Haas ffmpeg at haasn.xyz
Mon Jan 3 10:40:09 EET 2022


On Mon, 03 Jan 2022 01:27:22 +0100 Niklas Haas <ffmpeg at haasn.xyz> wrote:
> +/**
> + * Dolby Vision RPU data mapping parameters.
> + *
> + * @note sizeof(AVDOVIDataMapping) is not part of the public ABI.
> + */
> +typedef struct AVDOVIDataMapping {
> +    uint8_t vdr_rpu_id;
> +    uint8_t mapping_color_space;
> +    uint8_t mapping_chroma_format_idc;
> +    AVDOVIReshapingCurve curves[3]; /* per component */
> +
> +    /* Non-linear inverse quantization */
> +    enum AVDOVINLQMethod nlq_method_idc;
> +    uint32_t num_x_partitions;
> +    uint32_t num_y_partitions;
> +    AVDOVINLQParams nlq[3]; /* per component */
> +} AVDOVIDataMapping;

It just occurred to me that we also cannot make AVDOVIReshapingCurve or
AVDOVINLQParams extensible if we're going to store them in an array.

So I think that locks us into making these structs fixed size, avoiding
the issue altogether, but probably making future extensions to this API
somewhat uglier.

Thoughts?


More information about the ffmpeg-devel mailing list