When I exit my fullscreen SDL application, my computer resolution changes to 640×480.
My application resolution is 1024×768. How can I switch back the resolution to its original resolution after exiting the application?
I use SDL 1.2 and Ubuntu 10.04
That sounds like a X driver problem or window manager problem. Can you try it on different distro or different ubuntu version?
Unless your program crash, you should call
SDL_Quit(), orSDL_QuitSubSystem(SDL_INIT_VIDEO), or just exit the full screen. That should restore original settings.