SDL_image
SDL_image copied to clipboard
Restore support for lodepng?
This was supported very briefly in 2019 (added in commit d3d2b9635fee99e23a79305959da66eb657329c0, removed in commit ef2488c0ffb8972f8afc67ef500ba39c49b3d9ee). Since SDL_image now prefers using single header libraries, and stb_image lacks support for palette output (see #298), it might be worth restoring lodepng support and using it instead of stb_image and miniz.
Are there any downsides to using lodepng instead of stb_image for PNG support? Would it be easier to just modify stb_image to support palettes?
The only downside of lodepng I can think of compared to stb_image is that it doesn't support decoding from a SDL_RWops stream, so it's necessary to load the whole file into memory before decoding it. I don't know which would be the harder task between extending lodepng to support streams or extending stb_image to support palette output.
If this is only about png palette support of #298, there was a rejected PR draft at stb for it: https://github.com/nothings/stb/pull/788 I don't think that it applies directly today (haven't even tried myself) but maybe wort a look.
(Also possibly related: https://github.com/nothings/stb/pull/45)