Sign in to follow this  
Replicon

SDL_WM_SetIcon and .ico files

Recommended Posts

I'm trying to set the small window icon on an SDL app, but IMG_Load gives me "Unsupported image format" when trying to load the .ico file. Does SDL really not support it today, or am I just running an old SDL? Do I really have to make a bmp version of this thing? That sounds kind of silly...

Share this post


Link to post
Share on other sites
Quote:
Original post by Replicon
I'm trying to set the small window icon on an SDL app, but IMG_Load gives me "Unsupported image format" when trying to load the .ico file. Does SDL really not support it today, or am I just running an old SDL? Do I really have to make a bmp version of this thing? That sounds kind of silly...


Like SDL_image says... unsupported format. From the SDL_image docs:

"This is a simple library to load images of various formats as SDL surfaces.
This library supports BMP, PNM (PPM/PGM/PBM), XPM, LBM, PCX, GIF, JPEG, PNG,
TGA, and TIFF formats."

.ico is a windows specific thing, and you're not likely to want to use a .ico as an actual SDL_Surface, so it's not really surprising it's not supported. Just make a bmp.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this