We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 1721

Summary: ImageIO loader fails to load some png files from circuslinux
Product: SDL_image Reporter: nip
Component: miscAssignee: Sam Lantinga <slouken>
Status: REOPENED --- QA Contact: Sam Lantinga <slouken>
Severity: normal    
Priority: P2 CC: josh+sdl
Version: 1.2.12   
Hardware: PowerPC   
OS: Mac OS X 10.5 (PPC)   
Attachments: sample png

Description nip 2013-02-14 11:06:58 UTC
When compiled with ImageIO support, showimage fails to load some png files from circuslinux:

$ ./showimage /opt/local/share/circuslinux/data/images/title/programming.png 
Couldn't load /opt/local/share/circuslinux/data/images/title/programming.png: Unknown bits_per_pixel u

Same file loads ok when compiled with --disable-imageio

See https://trac.macports.org/ticket/38012
Comment 1 nip 2013-02-14 11:08:35 UTC
Created attachment 1043 [details]
sample png
Comment 2 Sam Lantinga 2013-06-03 02:01:22 UTC
This appears to be fixed in the SDL_image 2.0 release candidate.

Thanks!
Comment 3 Joshua Root 2016-04-29 12:42:24 UTC
I'm not so sure this is actually fixed. The test case on the MacPorts ticket shows that the 8-bit images are loaded fine but not the 2-bit colormaps. I suspect ImageIO on 10.5 just doesn't handle those (or at least does something unexpected with them). Nobody ever reported this problem with later OS versions.

Given that SDL2 doesn't work on 10.5 anyway it may be a moot point, but if you were inclined to fix it in a new 1.2.x release then the straightforward workaround would be to not use ImageIO on 10.5 or earlier. No idea if a real fix for 10.5 is even possible.

Feel free to just re-close as WONTFIX if you'd prefer.