When the player quits your game, you must remove any timers you installed and shut down SDL. Call the function SDL_RemoveTimer() to remove a timer. Call the function SDL_Quit() to shut down SDL.
SDL_bool success; SDL_TimerID timer; success = SDL_RemoveTimer(timer); SDL_Quit();
Included with this article is source code for a simple SDL application. It provides a nice starting point for people new to SDL and OpenGL development.
The SDL library is too large to completely cover in a single article. Mac OS X developers who download the SDL development libraries can read the SDL documentation at /Developer/Documentation/SDL. Documentation is also available at the SDL website.
Previous (SDL Event Loop)