OpenGL exclusive fullscreen mode
Hi,
As I know, in Direct3D, there are windowed mode and fullscreen mode in which the application uses the video card exclusively. My question is, in OpenGL, is there such an exclusive fullscreen mode? If yes, how can I switch my applications into that mode. Thanks a lot!
When creating an OpenGL window you set the fullscreen parameter.
E.G:
The first param is the window title, the second is the height, third is the width, fourth is the colour depth and the fifth is fullscreen.
E.G:
CreateGLWindow("Window Title",640,480,16,TRUE)
The first param is the window title, the second is the height, third is the width, fourth is the colour depth and the fifth is fullscreen.
Thanks a lot, Undeadlnsanity!
But is "CreateGLWindow" a standard OpenGL call? In fact, what I want to do is to detect an exclusive fullscreen OpenGL application. I think I need to hook the OpenGL method that an application may use to switch itself into fullscreen mode. Is there such a standard OpenGL method?
But is "CreateGLWindow" a standard OpenGL call? In fact, what I want to do is to detect an exclusive fullscreen OpenGL application. I think I need to hook the OpenGL method that an application may use to switch itself into fullscreen mode. Is there such a standard OpenGL method?
Quote:Original post by tc_tianchao
My question is, in OpenGL, is there such an exclusive fullscreen mode?
That depends entirely on the operating system and environment. Yes, some systems (for example, Windows, Linux and MacOS) do provide this feature, but the method for doing it is platform-specific.
Some platforms of course support nothing else (Consoles, DOS)
Quote:
If yes, how can I switch my applications into that mode. Thanks a lot!
In some cases you can't "switch" your applications into that mode, you have to choose it at startup (i.e. when (or before) the gl context is created).
Mark
Thanks, Geocyte and markr!
In fact, I only care about Windows OS.
markr, do you mean that an application needs to call Windows APIs such as "ChangeDisplaySettings" to get itself in fullscreen mode, and OpenGL itself has no such functionality since it is platform independent?
Actually, what I want to find out is what an OpenGL application will do if it wants to use the video card EXCLUSIVELY. (I don't think "ChangeDisplaySettings" can tell the system whether the application will use the video card exclusively.) Thanks a lot!
In fact, I only care about Windows OS.
markr, do you mean that an application needs to call Windows APIs such as "ChangeDisplaySettings" to get itself in fullscreen mode, and OpenGL itself has no such functionality since it is platform independent?
Actually, what I want to find out is what an OpenGL application will do if it wants to use the video card EXCLUSIVELY. (I don't think "ChangeDisplaySettings" can tell the system whether the application will use the video card exclusively.) Thanks a lot!
The CreateGLWindow looks like the NEHE function that wraps up most of the intialization required to get OpenGL running. Using ChangeDisplaySetting correctly should work. I don't understand why you need "exclusive" mode for anything. I think you should go fullscreen mode and leave it at that. Remember, the user might want to alt-tab out of the game so you need to be set up for that to happen. This applies especially in a windows environment because that is why windows was made the way it was, multi-tasking.
I think he means that when it goes fullscreen, if you can make it so that only that application has access to the video card, in other words, the video card is all to program when it's in fullscreen.
Also, CreateGLWindow, that's a real function? What library/header?
EDIT: Either it's from SDL or you create it yourself, if you want to know how to create it yourself, I found a very nice page: http://www.morrowland.com/apron/tutorials/gl/gl_window.php
Also, to not waste space and create a new thread, is it possible to go into Fullscreen once already running the app? I know it is, what a dumb question, cause I've seen it in games, but can anyone refer me to any code that does this? Thanks.
Also, CreateGLWindow, that's a real function? What library/header?
EDIT: Either it's from SDL or you create it yourself, if you want to know how to create it yourself, I found a very nice page: http://www.morrowland.com/apron/tutorials/gl/gl_window.php
Also, to not waste space and create a new thread, is it possible to go into Fullscreen once already running the app? I know it is, what a dumb question, cause I've seen it in games, but can anyone refer me to any code that does this? Thanks.
CreateGLWindow (as mention before) comes from nehe tutorials. See http://nehe.gamedev.net/data/lessons/lesson.asp?lesson=01
ChangeDisplaySettings will change to and from fullscreen mode during runtime. Refer to the link above to see how this function is used.
ChangeDisplaySettings will change to and from fullscreen mode during runtime. Refer to the link above to see how this function is used.
Thanks, guys!
kburkhart84, this is why I need to know what an OpenGL app will do if it wants to use the video card exclusively. While an exclusive fullscreen game is running, if I start a second exclusive fullscreen game (maybe by calling "CreateProcess" in a program), there will be a conflict and the second game may fail. What I need to do is to detect such games so that I can do something to prevent the conflict to happen. Does anyone have an idea?
kburkhart84, this is why I need to know what an OpenGL app will do if it wants to use the video card exclusively. While an exclusive fullscreen game is running, if I start a second exclusive fullscreen game (maybe by calling "CreateProcess" in a program), there will be a conflict and the second game may fail. What I need to do is to detect such games so that I can do something to prevent the conflict to happen. Does anyone have an idea?
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement