https://bugs.kde.org/show_bug.cgi?id=525876
--- Comment #5 from [email protected] --- (In reply to Zamundaaa from comment #4) > Right, that's just not the right curve. Screenshots use gamma 2.2, not the > piece-wise curve. Ah, I did not understand the screenshot was intended to use a pure 2.2 power function encoding. Because this is the intended behaviour, this is not a bug per se. In practice, it often doesn't matter what the encoding of a PNG file is because the colour will be presented "as is" with no conversions. But, although sRGB did not exist when the PNG format was first created, it is now most common for PNG files to be sRGB-encoded. So for cases where software must interpret colour from a PNG file, such as converting colour to linear encoding, it is reasonable to assume that the PNG file uses sRGB encoding for its colour, rather than a 2.2 power function. This is what both Krita and Godot will do when interpreting these PNG files and converting them to linear values. It has the added benefit of being able to easily convert the PNGs to "sRGB textures" in OpenGL that make use of the sRGB decoding functions, sometimes implemented in hardware, to correctly apply texture filtering on linear values, for mipmaps, etc. ( see https://wikis.khronos.org/opengl/Image_Format#sRGB_colorspace and https://registry.khronos.org/OpenGL-Refpages/es3/html/glTexImage3D.xhtml ) You can see this behaviour in Krita by opening one of the PNG screenshot files attached to this bug in Krita and: 1) Select "Image -> Convert Image Color Space" 2) Change Depth to 32-bit float/channel 3) Use the colour picker to inspect the colours Notice that the linear colour values reported by the colour picker suggest that the PNG screenshot was interpreted as having sRGB encoding, rather than a 2.2 power function. Again, this is the correct behaviour for the vast majority of PNG files. The 2.2-power-encoded screenshots in question are an outlier, which makes it difficult for colour to be correctly interpreted by other software. -- You are receiving this mail because: You are watching all bug changes.
