Jump to content

  • Log In with Google      Sign In   
  • Create Account

Fullscreen switching


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
5 replies to this topic

#1 Icarus3   Members   -  Reputation: 122

Like
Likes
Like

Posted 18 September 2001 - 06:41 PM

What steps should i take to switch from windowed mode to fullscreen and reverse???

Sponsor:

#2 Lang Fox   Members   -  Reputation: 122

Like
Likes
Like

Posted 18 September 2001 - 07:24 PM

Go to see NeHe''s turiol

#3 the darkening   Members   -  Reputation: 122

Like
Likes
Like

Posted 22 September 2001 - 01:35 AM

To enter fullscreen mode:

DEVMODE DisplayMode;

DisplayMode.dmSize = sizeof(DEVMODE);
DisplayMode.dmPelsWidth = ;
DisplayMode.dmPelsHeight = ;
DisplayMode.dmBitsPerPel = ;
DisplayMode.dmFields = DM_PELSWIDTH | DM_PELSHEIGHT | DM_BITSPERPEL;

ChangeDisplaySettings(&DisplayMode, CDS_FULLSCREEN);
---

To leave it:

ChangeDisplaySettings(NULL, CDS_FULLSCREEN);
---


Darkening

#4 FXO   Members   -  Reputation: 122

Like
Likes
Like

Posted 22 September 2001 - 04:11 AM

Darkening is right.

One strange thing though is that you must reset the display to windows desktop when switching resolutions inside the program. Or else the desktop will look messed up when you exit you program (at least this is what happens on my drivers/win98).

Anybody know a workaround for this?

Nehe''s homepage:
http://nehe.gamedev.net/

check out "basecode" or "lesson 1".

#5 Anonymous Poster_Anonymous Poster_*   Guests   -  Reputation:

Likes

Posted 22 September 2001 - 08:14 PM

Is it the same way while I using VC++ ''s MFC? I mean not a win32 program?

Thanks.

#6 Qoy   Members   -  Reputation: 127

Like
Likes
Like

Posted 22 September 2001 - 09:46 PM

AP: It''s the same with MFC, yes. Keep in mind switching to fullscreen might mess up any windows you already have showing, but ChangeDisplaySettings is just a windows call so it works no matter how you are displaying your windows. If you want your window to be created in the new mode, be sure to call ChangeDisplaySettings before you create the window.

FXO: There is no workaround.. if you change the settings you must change them back, just like with most things. It''s just like having to call Release() or whatever for DirectX objects, except in DirectX changing screen modes is built into the API and with OpenGL you must rely on the operating system functions to do it, but that doesn''t mean you don''t have to clean up.




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS