| Summary: | Add a function to load an XPM image directly as a RGB888 surface | ||
|---|---|---|---|
| Product: | SDL_image | Reporter: | Sylvain <sylvain.becker> |
| Component: | misc | Assignee: | Sam Lantinga <slouken> |
| Status: | WAITING --- | QA Contact: | Sam Lantinga <slouken> |
| Severity: | normal | ||
| Priority: | P2 | ||
| Version: | unspecified | ||
| Hardware: | All | ||
| OS: | All | ||
| Attachments: | path | ||
What's the use case for this? My use case is probably marginal. I have a few xpm files that I rescale linearly at run-time, so I need something else that a palette format. So, this function prevents a call to SDL_ConvertFormat() to converting them out of a palletized format. Moreover, this way, surfaces are also immediately in the natural renderer pixel format. |
Created attachment 3066 [details] path It would be nice to have a function that loads directly an XPM image as RGB888 surface. Path already exists in SDL_image. so the patch is almost only to expose this as a function. (remove also MAX macro un-used).