On Wed, 20 Sep 2017 04:00:27 +0100 Rostislav Pehlivanov <atomnu...@gmail.com> wrote:
> PNG exposes it and its required in order to correctly display some images, > particularly images crafted to contain 2 different images which appear > differently depending on whether the gamma has been taken into account. > > Signed-off-by: Rostislav Pehlivanov <atomnu...@gmail.com> > --- > libavutil/mastering_display_metadata.h | 10 ++++++++++ > libavutil/version.h | 2 +- > 2 files changed, 11 insertions(+), 1 deletion(-) > > diff --git a/libavutil/mastering_display_metadata.h > b/libavutil/mastering_display_metadata.h > index 847b0b62c6..3de58bf468 100644 > --- a/libavutil/mastering_display_metadata.h > +++ b/libavutil/mastering_display_metadata.h > @@ -66,6 +66,16 @@ typedef struct AVMasteringDisplayMetadata { > */ > int has_luminance; > > + /** > + * The power-law response exponent needed to compensate for nonlinearity. > + */ > + AVRational gamma; > + > + /** > + * Flag indicating whether the gamma has been set. > + */ > + int has_gamma; > + > } AVMasteringDisplayMetadata; Why have the last field, instead of making gamma={0,0} mean unset? _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel