Sign in to follow this  
password

Changing exe icon

Recommended Posts

I know how to change the window icon and the other icon that is shown in the application tab. Now I also want to change the exe icon but it seems the SDL_WM_SetIcon function cannot do that. I am using the following line right before setting the video mode. Icon.bmp is 32x32.
SDL_WM_SetIcon(SDL_LoadBMP("gfx/icon.bmp"), NULL);

So what's the secret behind this that I can't find about anywhere on the net or any book using SDL?

Share this post


Link to post
Share on other sites
That actually depends on your ide more than anything. If you use MSVC, you can do the following:

Go to "Add Resource", Select "Icon". Click "New". Now you can copy & paste in your icon. You can add more by doing "Image->New Image Type" from the menu. You should do a 16x16 one and a 32x32 one.

Hope that works for you.

Share this post


Link to post
Share on other sites
I see, i'm using dev-c++ and just remember that I found a browse after icon function in project options. The only problem now is that I don't have anything to create .ico files with or something to convert bmp/png/gif/etc to .ico files. Visual C++ Express Edition doesn't seem to have the functionality to create icons like the normal versions have.

Share this post


Link to post
Share on other sites
It's okay. I can look for something that can convert ico files. I'm sure there are tons of programs that can convert them.
Thank you.

Share this post


Link to post
Share on other sites
I've recently discovered IcoFX. Also free and seems pretty good.

I was wondering about how to set the application icon with VS. I note that "Add Resource" is greyed out in my VS Express. Is this something only available in the non-Express versions or am I doing something wrong?

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