diff options
author | Leo Izen <leo.izen@gmail.com> | 2023-01-17 12:32:31 -0500 |
---|---|---|
committer | Leo Izen <leo.izen@gmail.com> | 2023-01-25 08:09:20 -0500 |
commit | f7bab37c8e66f3c77a5fbb5b5b72c10b0fb4ca5a (patch) | |
tree | 2400247ccba39727c104de643114e04f60052634 /libavcodec/dnxhd_parser.c | |
parent | 2548c32cc10f256cc0ff90457631ef7ef94070af (diff) | |
download | ffmpeg-f7bab37c8e66f3c77a5fbb5b5b72c10b0fb4ca5a.tar.gz |
avcodec/pngdec: support decoding sRGB chunks
If an sRGB chunk is present in the PNG file, this commit will cause the
png decoder to ignore the cHRM and gAMA chunks and tag the resulting AVFrames
with BT.709 primaries, and ISO/IEC 61966-2-1 transfer. If these tags are
present in the AVFrame, pngenc.c already writes this chunk, so no change was
needed on the encode-side.
The PNG spec does not define what happens if sRGB and iCCP are present at
the same time, it just recommends that this not happen. As of this patch,
the decoder will have the ICC profile take precedence, and it will not tag
the pixel data as sRGB.
Signed-off-by: Leo Izen <leo.izen@gmail.com>
Diffstat (limited to 'libavcodec/dnxhd_parser.c')
0 files changed, 0 insertions, 0 deletions