View Full Version : Switching between windowed and full-screen

11-02-2001, 04:57 PM
Anyone had problems changing a OpenGL window on the fly from normal windowed to fullscreen in Windows (I'm using W2K)? I don't mean changing screen resolutions, just changing the style of the window from WS_OVERLAPPED to WS_POPUP with the appropriate SetWindowPos dimensions. Works fine or only slightly quirky on some systems (GeForce3/DetXP), and completely blows the O/S on others (misc ATI). Is this a technique that others have used (meaning I'm probably seeing driver problems), or is this just not allowed/recommended? Thanks!

Rob The Bloke
11-04-2001, 07:28 AM
have a look on the nehe site at the basic code he impliments - allows you to do it.

11-04-2001, 03:54 PM
For one, I'm already switching between full-screen and windowed on the fly. It just doesn't seem reliable on some driver/card combinations.

I've been to NeHe - looks to me like the window is created and destroyed when switching between windowed and full-screen - it's not performed on the fly. That's easy, and not at all what I'm trying to do.

Spiral Man
11-04-2001, 04:03 PM
why dont you want to do this? its completely seemless, and would most likely get rid of all the reliability issues.

what are you doing that you cant destroy a window and create an identical one in full screen mode?

11-05-2001, 02:20 AM
When im switching to fullscreen mode on my TNT2 card, the v-sync is enabled and backbuffer is not copied but flipped. That situation does not happen (by default v-sync is off, buffer is copied) in windowed mode. These settings are associated with created context, so after you create context you cannot change style of the window without errors. YOU MUST DESTROY AND CREATE CONTEXT AGAIN.

Sorry For Bas English.

11-05-2001, 06:46 AM
That's the same behavior I see on my GeForce3 with the Detonator XP drivers. Thanks for the tips, folks - the switch on the fly stuff is coming out of my progs.