735 |
|
// This is ugly: |
736 |
|
// If we're switching resolutions (ie, not setting it for the first time), |
737 |
|
// there's a bug in SDL where the SDL_Surface created will not be properly |
738 |
< |
// setup. The solution is to SDL_Quit() before calling SDL_SetVideoMode for |
739 |
< |
// the second time (SDL_SetVideoMode will call SDL_Init() and all will be |
740 |
< |
// well). Without this, the video becomes corrupted (at least on Mac OS X), |
741 |
< |
// after the resolution switch (for the second and subsequent times). |
738 |
> |
// setup. The solution is to SDL_QuitSubSystem(SDL_INIT_VIDEO) before calling |
739 |
> |
// SDL_SetVideoMode for the second time (SDL_SetVideoMode will call SDL_Init() |
740 |
> |
// and all will be well). Without this, the video becomes corrupted (at least |
741 |
> |
// on Mac OS X), after the resolution switch. |
742 |
|
if (SDL_display_opened) |
743 |
< |
SDL_Quit(); |
743 |
> |
SDL_QuitSubSystem(SDL_INIT_VIDEO); |
744 |
|
|
745 |
|
// Create surface |
746 |
|
int depth = sdl_depth_of_video_depth(VIDEO_MODE_DEPTH); |