| Summary: | IMG_Load_RW does not set PixelFormat of attached image correctly | ||
|---|---|---|---|
| Product: | SDL_image | Reporter: | Tobbi <tobbi.bugs> |
| Component: | misc | Assignee: | Sam Lantinga <slouken> |
| Status: | RESOLVED INVALID | QA Contact: | Sam Lantinga <slouken> |
| Severity: | normal | ||
| Priority: | P2 | CC: | sylvain.becker |
| Version: | 2.0.0 | ||
| Hardware: | x86 | ||
| OS: | Other | ||
| Attachments: | example file this was tried on | ||
I tried and it displays correctly. format "318769153" is SDL_PIXELFORMAT_INDEX8, which is a palette. (you can use "SDL_GetPixelFormatName(format)") |
Created attachment 2058 [details] example file this was tried on I noticed this with the attached file (for example). I'm trying to load it via this command: image = IMG_Load_RW(get_physfs_SDLRWops(filename), 1); The image appears white because the format information seems to be set to 0. Here is an example debug output: /images/tiles/waterfall/waterfall-1.png: (Format)318769153 (Bits per Pixel) (Bytes per Pixel) (RMask)0 (GMask)0 (BMask)0 (AMask)0