You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using stb_image_write I have a problem that I do not know if any transformations (sRGB gamut, color space conversions, etc) are being applied to the data I'm saving. I looked in the documentation and I couldn't find any documentation on the intended behavior.
Describe the solution you'd like
I just want some kind of documentation on what, if anything, stb_image_write does to my data. Am I supposed to apply the sRGB gamut myself? Does it specify any colorspace in the file?
Describe alternatives you've considered
An alternative would be to add an API for specifying which transformations you want to apply to your data. While useful this solution would add extra API surface and is probably not worth it.
Additional context
I only really care about what happens when I save to .png so if only that format is documented that's fine with me.
The text was updated successfully, but these errors were encountered:
For lossless file formats (everything but JPEG), the data is written to the file unaltered, exactly as you passed it in. No tags specifying color profile or gamma are written.
8-bit input data cannot be meaningfully transformed to other 8-bit output data without significant loss (a variant on the pigeonhole principle). The lack of transformation is not documented because no such transformation would ever make sense, since it would be so lossy.
Does it hurt to add a statement in the documentation that explicitly states that no transformation on the data is done? It was not obvious to me that no such transformations would be applied, so I went looking in the documentation and didn't find anything.
When using stb_image_write I have a problem that I do not know if any transformations (sRGB gamut, color space conversions, etc) are being applied to the data I'm saving. I looked in the documentation and I couldn't find any documentation on the intended behavior.
Describe the solution you'd like
I just want some kind of documentation on what, if anything, stb_image_write does to my data. Am I supposed to apply the sRGB gamut myself? Does it specify any colorspace in the file?
Describe alternatives you've considered
An alternative would be to add an API for specifying which transformations you want to apply to your data. While useful this solution would add extra API surface and is probably not worth it.
Additional context
I only really care about what happens when I save to
.png
so if only that format is documented that's fine with me.The text was updated successfully, but these errors were encountered: