If I am running fullscreen, is it ever a bad idea to...

Started by
24 comments, last by PlayGGY 20 years, 4 months ago
quote:Original post by PlayGGY
Well, I just Alt+Tab, read the Debug messages, and Alt+Tab back.


When you Alt+Tab out you lose your device, so if you step through code in the debugger many calls will fail that normally wouldn''t. Being able to see debug messages while things are running can also be a huge help.

Honestly, making it so you can start in windowed or fullscreen is VERY easy. If you check out my tutorials they all pop up a message box to prompt for fullscreen or windowed and all the code is there (there isn''t a lot involved) to handle both modes. The code is free to use and doesn''t use any frameworks so you can just drop it in to your code with minimal effort.

Stay Casual,

Ken
Drunken Hyena
Stay Casual,KenDrunken Hyena
Advertisement
I correctly handle lost devices though.

But I will add windowed functionality to my engine, after I finish the rest of it. Right now it is set up for fullscreen mode.

The hardest part will be dealing with the damn WndProc...
And the rockets' red glare, the bombs bursting in air,gave proof through the fight that our flag was still there.Oh say, does that star-spangled banner yet waveover the land of the free and the home of the brave?
I don''t see what the problem is for making windowed or fullscreen mode. It''s simple!
//D3D9 is what I''m showing herevoid InitD3D(bool WindowedMode){D3DPRESENT_PARAMETERS d3dParams;d3dParams.Windowed = WindowedMode;//rest of initialization code} 


That''s the only place I ever have to specify wether it''s windowed or not. Of course there are other places where I check, but that''s because of features I can only use in fullscreen mode (multiple monitors) or problems that only occur in fullscreen mode (losing devices).

The only thing that I''m not sure if you have to do differently is that you have to specify the window on your CreateDevice call. I don''t know if it''s required in Fullscreen mode, but it works fine.
----Erzengel des Lichtes光の大天使Archangel of LightEverything has a use. You must know that use, and when to properly use the effects.♀≈♂?
quote:Original post by PlayGGY
I correctly handle lost devices though.


Sure, but you can only recover the device when you alt-tab back in to the app, and likely only at the end of your render loop. This makes it impossible to step through code in the middle of your render loop.

quote:
The hardest part will be dealing with the damn WndProc...

What''s the difficulty with WndProc?


Stay Casual,

Ken
Drunken Hyena
Stay Casual,KenDrunken Hyena
quote:Original post by Erzengeldeslichtes
That''s the only place I ever have to specify wether it''s windowed or not. Of course there are other places where I check, but that''s because of features I can only use in fullscreen mode (multiple monitors) or problems that only occur in fullscreen mode (losing devices).

The only thing that I''m not sure if you have to do differently is that you have to specify the window on your CreateDevice call. I don''t know if it''s required in Fullscreen mode, but it works fine.


Additionally you should check back buffer formats differently and probably create the window differently as well. But it is really easy to do.

And yes, even in fullscreen you still need the window.

Stay Casual,

Ken
Drunken Hyena
Stay Casual,KenDrunken Hyena
True, allow users to choose from a list of supported backgrounds in fullscreen mode, but in windowed mode you have to stick them to their windows desktop. That''s on my todo list, right now I just stick them to their desktop, which works fine for debugging and doesn''t require a switch between windowed and fullscreen mode.
----Erzengel des Lichtes光の大天使Archangel of LightEverything has a use. You must know that use, and when to properly use the effects.♀≈♂?

This topic is closed to new replies.

Advertisement