Fullscreen in OpenGL...

Started by
13 comments, last by ZaneX 23 years, 6 months ago
I've posted this already on NeHe's Forum, but getting little response (I still apreciate the help giving to me by those who have) but I find that I need more input, so if anybody else can help out It would really be appreciated. The problem is already stated here: Fullscreen in OpenGL... I really need to know how to get this working, otherwise I might be forced to bring back my video card. I really want fullscreen OpenGL w/ acceleration WITHOUT having to change my desktops bit depth to 16bpp. All comments are appreciated! ZaneX Edited by - ZaneX on 10/4/00 7:20:38 AM
Advertisement
The best way I am aware of with Windows and OpenGL is to create your window with CreateWindowEx and use the WS_EX_TOPMOST flag. Then you set the width and height to that of the screen with GetSytemMetrics();
The NeHe Tuts explain very well how to set fullscreen mode
I think its the SetDeviceMode or something like that function
It should set the bitdepth for you without worrying about desktop settings. It works for me.

Chris
TheLabRat... NeHe''s tutorials are great and do explain it well, but I have a problem with his frame work, my Voodoo3 3000 doesn''t want to go to fullscreen mode for some reason, and it should, at least I can''t see why not. Anyways, I should have more time this weekend to fool around with the code and I''m hoping that Win98 will fix the problem (I''m still running 95). If you''re more curious on what is happening, the thread in NeHe''s forum explains more in detail to what I''ve been going through...

ZaneX
I suppose it''s an obvious piece of advice, but are you running the latest drivers - if you''re running beta drivers this might be a problem.
I have a Voodoo3 as well, and with the original drivers, opengl would not accelerate at all. I downloaded later drivers and all problems were fixed. Unfortunately, 3dfx make very big downloads.
Sorry if this is patronistic

Chris
There is a Win32 API function to change the color depth of the display without using DirectX, I think. Look at the Resolution Switching Without using DirectX article, although your game will now not work with Win95 before version a because it cannot change color depth without restarting. You might just have to change your desktop color depth.

------------------------------
#pragma twice


sharewaregames.20m.com

Bringing back your video card would be a perfect idea anyway ! 3Dfx has the worst OpenGL drivers in the history of computer gfx, so you are really out of luck if you are trying to code anything GL for that card...

Tim

--------------------------
glvelocity.gamedev.net
www.gamedev.net/hosted/glvelocity
Tim--------------------------glvelocity.gamedev.netwww.gamedev.net/hosted/glvelocity
Ya I could bring it back, but what am I suppose to get??? I need a PCI card 'cause I don't have the money to upgrade my system. I'm also limited to a 130$(US) price range!

ZaneX

Edited by - ZaneX on October 6, 2000 12:24:46 PM
I''m not sure if this helps, but I''ve been doing some OpenGL coding for a Voodoo3 and I had some problems that sound similar to yours. The basic problem was that is wasn''t properly changing screen resolution (the scene would be clipped). I fixed this by changing the location of my call to glViewport. When you first bind the OpenGL rendering context to your window it assumes the width and height of the current context (the desktop) as your viewport. Then it would change the screen resolution to 800 by 600 or whatever, so the two values would be misaligned. By adding your call to glViewport after your initial OpenGL setup you can set it right again.

This fixed my problem, but you may be facing something else entirely.
-----------------------------Mice are an excellent source of mice.
Jo...

It does sound like I have the same problem... I'll give your solution a try, hopefully it'll work. (If you could spare a framework of your source, it would save me some time)

ZaneX


Edited by - ZaneX on October 6, 2000 2:24:31 PM

This topic is closed to new replies.

Advertisement