11/*
2- LodePNG version 20241228
2+ LodePNG version 20250506
33
4- Copyright (c) 2005-2024 Lode Vandevenne
4+ Copyright (c) 2005-2025 Lode Vandevenne
55
66This software is provided 'as-is', without any express or implied
77warranty. In no event will the authors be held liable for any damages
@@ -670,15 +670,15 @@ typedef struct LodePNGInfo {
670670 unsigned cicp_video_full_range_flag; /* Video full range flag value */
671671
672672 /*
673- mDCv chunk: Mastering Display Color Volume.
673+ mDCV chunk: Mastering Display Color Volume.
674674 Optional, typically used in conjunction with certain HDR color spaces that can
675675 be represented by the cICP chunk.
676676 See the PNG specification, third edition, for more information on this chunk.
677677 All the red, green, blue and white x and y values are encoded as 16-bit
678678 integers and therefore must be in range 0-65536. The min and max luminance
679679 values are 32-bit integers.
680680 */
681- unsigned mdcv_defined; /* Whether a mDCv chunk is present (0 = not present, 1 = present). */
681+ unsigned mdcv_defined; /* Whether an mDCV chunk is present (0 = not present, 1 = present). */
682682 /* Mastering display color primary chromaticities (CIE 1931 x,y of R,G,B) */
683683 unsigned mdcv_red_x; /* Red x times 50000 */
684684 unsigned mdcv_red_y; /* Red y times 50000 */
@@ -694,13 +694,13 @@ typedef struct LodePNGInfo {
694694 unsigned mdcv_min_luminance; /* Min luminance in cd/m^2 times 10000 */
695695
696696 /*
697- cLLi chunk: Content Light Level Information.
697+ cLLI chunk: Content Light Level Information.
698698 Optional, typically used in conjunction with certain HDR color spaces that can
699699 be represented by the cICP chunk.
700700 See the PNG specification, third edition, for more information on this chunk.
701701 The clli_max_cll and clli_max_fall values are 32-bit integers.
702702 */
703- unsigned clli_defined; /* Whether a cLLi chunk is present (0 = not present, 1 = present). */
703+ unsigned clli_defined; /* Whether a cLLI chunk is present (0 = not present, 1 = present). */
704704 unsigned clli_max_cll; /* Maximum Content Light Level (MaxCLL) in cd/m^2 times 10000 */
705705 unsigned clli_max_fall; /* Maximum Frame-Average Light Level (MaxFALL) in cd/m^2 times 10000 */
706706
@@ -1279,7 +1279,7 @@ unsigned compress(std::vector<unsigned char>& out, const std::vector<unsigned ch
12791279[X] converting color to 16-bit per channel types
12801280[X] support color profile chunk types (but never let them touch RGB values by default)
12811281[ ] support all second edition public PNG chunk types (almost done except sPLT and hIST)
1282- [X] support non-animation third edition public PNG chunk types: eXIf, cICP, mDCv, cLLi
1282+ [X] support non-animation third edition public PNG chunk types: eXIf, cICP, mDCV, cLLI
12831283[ ] make sure encoder generates no chunks with size > (2^31)-1
12841284[ ] partial decoding (stream processing)
12851285[X] let the "isFullyOpaque" function check color keys and transparent palettes too
@@ -2019,12 +2019,13 @@ symbol.
20192019Not all changes are listed here, the commit history in github lists more:
20202020https://github.com/lvandeve/lodepng
20212021
2022- *) 16 apr 2025: added public lodepng_decode_chunks and lodepng_finish_decode
2023- functions. With these a user can separate decode of all the chunks, so as
2024- to learn all the details of the file, from decompression, and possible
2025- conversion, of the image data .
2022+ *) 6 may 2025: renamed mDCv to mDCV and cLLi to cLLI as per the recent rename
2023+ in the draft png third edition spec. Please note that while the third
2024+ edition is not finalized, backwards-incompatible changes to its features are
2025+ possible .
20262026*) 16 apr 2025: Separated chunk decoding from image decoding and expansion.
2027-
2027+ so a user can first decode all the chunks to learn details of the file
2028+ then decompress and, possibly, convert the image data.
20282029*) 23 dec 2024: added support for the mDCv and cLLi chunks (for png third
20292030 edition spec)
20302031*) 22 dec 2024: added support for the cICP chunk (for png third edition spec)
@@ -2035,7 +2036,7 @@ Not all changes are listed here, the commit history in github lists more:
20352036*) 27 jun 2021: added warnings that file reading/writing functions don't support
20362037 wide-character filenames (support for this is not planned, opening files is
20372038 not the core part of PNG decoding/decoding and is platform dependent).
2038- *) 17 okt 2020: prevent decoding too large text/icc chunks by default.
2039+ *) 17 oct 2020: prevent decoding too large text/icc chunks by default.
20392040*) 06 mar 2020: simplified some of the dynamic memory allocations.
20402041*) 12 jan 2020: (!) added 'end' argument to lodepng_chunk_next to allow correct
20412042 overflow checks.
@@ -2057,7 +2058,7 @@ Not all changes are listed here, the commit history in github lists more:
20572058*) 09 apr 2016: Fixed colorkey usage detection, and better file loading (within
20582059 the limits of pure C90).
20592060*) 08 dec 2015: Made load_file function return error if file can't be opened.
2060- *) 24 okt 2015: Bugfix with decoding to palette output.
2061+ *) 24 oct 2015: Bugfix with decoding to palette output.
20612062*) 18 apr 2015: Boundary PM instead of just package-merge for faster encoding.
20622063*) 24 aug 2014: Moved to github
20632064*) 23 aug 2014: Reduced needless memory usage of decoder.
@@ -2071,8 +2072,8 @@ Not all changes are listed here, the commit history in github lists more:
20712072 prefix for the custom allocators and made it possible with a new #define to
20722073 use custom ones in your project without needing to change lodepng's code.
20732074*) 28 jan 2013: Bugfix with color key.
2074- *) 27 okt 2012: Tweaks in text chunk keyword length error handling.
2075- *) 8 okt 2012: (!) Added new filter strategy (entropy) and new auto color mode.
2075+ *) 27 oct 2012: Tweaks in text chunk keyword length error handling.
2076+ *) 8 oct 2012: (!) Added new filter strategy (entropy) and new auto color mode.
20762077 (no palette). Better deflate tree encoding. New compression tweak settings.
20772078 Faster color conversions while decoding. Some internal cleanups.
20782079*) 23 sep 2012: Reduced warnings in Visual Studio a little bit.
@@ -2088,7 +2089,7 @@ Not all changes are listed here, the commit history in github lists more:
20882089*) 6 nov 2011: (!) By default, the encoder now automatically chooses the best
20892090 PNG color model and bit depth, based on the amount and type of colors of the
20902091 raw image. For this, autoLeaveOutAlphaChannel replaced by auto_choose_color.
2091- *) 9 okt 2011: simpler hash chain implementation for the encoder.
2092+ *) 9 oct 2011: simpler hash chain implementation for the encoder.
20922093*) 8 sep 2011: lz77 encoder lazy matching instead of greedy matching.
20932094*) 23 aug 2011: tweaked the zlib compression parameters after benchmarking.
20942095 A bug with the PNG filtertype heuristic was fixed, so that it chooses much
@@ -2103,8 +2104,8 @@ Not all changes are listed here, the commit history in github lists more:
21032104*) 13 nov 2010: added LodePNG_InfoColor_hasPaletteAlpha and
21042105 LodePNG_InfoColor_canHaveAlpha functions for convenience.
21052106*) 7 nov 2010: added LodePNG_error_text function to get error code description.
2106- *) 30 okt 2010: made decoding slightly faster
2107- *) 26 okt 2010: (!) changed some C function and struct names (more consistent).
2107+ *) 30 oct 2010: made decoding slightly faster
2108+ *) 26 oct 2010: (!) changed some C function and struct names (more consistent).
21082109 Reorganized the documentation and the declaration order in the header.
21092110*) 08 aug 2010: only changed some comments and external samples.
21102111*) 05 jul 2010: fixed bug thanks to warnings in the new gcc version.
@@ -2163,8 +2164,8 @@ Not all changes are listed here, the commit history in github lists more:
21632164 Removed some code duplication in the decoder. Fixed little bug in an example.
21642165*) 09 dec 2006: (!) Placed output parameters of public functions as first parameter.
21652166 Fixed a bug of the decoder with 16-bit per color.
2166- *) 15 okt 2006: Changed documentation structure
2167- *) 09 okt 2006: Encoder class added. It encodes a valid PNG image from the
2167+ *) 15 oct 2006: Changed documentation structure
2168+ *) 09 oct 2006: Encoder class added. It encodes a valid PNG image from the
21682169 given image buffer, however for now it's not compressed.
21692170*) 08 sep 2006: (!) Changed to interface with a Decoder class
21702171*) 30 jul 2006: (!) LodePNG_InfoPng , width and height are now retrieved in different
0 commit comments