ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/cebix/BasiliskII/src/SDL/video_sdl.cpp
(Generate patch)

Comparing BasiliskII/src/SDL/video_sdl.cpp (file contents):
Revision 1.30 by asvitkine, 2007-01-21T19:33:13Z vs.
Revision 1.32 by asvitkine, 2007-01-22T00:36:32Z

# Line 735 | Line 735 | driver_window::driver_window(SDL_monitor
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);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines