1 Jul 2008 04:06
Full Screen Toggle
Peter Ketting <peterketting <at> sysmatrix.net>
2008-07-01 02:06:47 GMT
2008-07-01 02:06:47 GMT
Hi all, I've implemented a windowed/full screen toggle into my game. It does this by calling SDL_QuitSubSystem (SDL_INIT_VIDEO) to close the window / screen, and then re-initialises it with SDL_InitSubSystem (SDL_INIT_VIDEO) before re-creating the primary surface. Is this about the right way to go about it? This method works well for me, but someone who used dual monitors experienced a crash when trying to re-initialise the video system (though going straight to full-screen at the start did not pose any problems). Cheers, Peter p.s.: I never thought this much through, but it seems that all other created surfaces remain unchanged after calling SDL_QuitSubSystem (SDL_INIT_VIDEO), is this something I can rely on?
RSS Feed