Cosmetical Error While Closing DirectX

Started by
29 comments, last by Despotismo 23 years, 6 months ago
Does it happens to everybody that when you finish your DirectX application, if run from the Visual Studio Interface, then it appears with the size reduced, and, if you are using any pop-up programs (ie ICQ), it also appears with the size reduced? It seems that the programs adjust their size to the DirectX resolution used in the game. Has anyone managed to solve this problem? Despotismo AKA Javier Otaegui Sabarasa Entertainment www.sabarasa.com.ar
Despotismo AKA Javier OtaeguiSabarasa Entertainmentwww.sabarasa.com.ar
Advertisement
Yup, happens to me too. I haven''t found a solutin for ICQ other than just putting it in the left corner intead, but you can just de-maximize the VStudio window and stretch it to full screen by hand and it works just fine^^


-Deku-chan

DK Art (my site, which has little programming-related stuff on it, but you should go anyway^_^)

"I'm dropping like flies!" - me, playing Super Smash Bros. (and losing)
"What fun!" - me, playing Super Smash Bros. (and beating the crap out of somebody)
That''s true, but it''s not so elegant. The problem is that when common users of the game play it, everything must be fine, and I should leave the programs in the desktop exactly as I found them.

I think that perhaps by inverting something in the closing sequence of the game, this can be worked around.

Despotismo AKA Javier Otaegui
Sabarasa Entertainment
www.sabarasa.com.ar
Despotismo AKA Javier OtaeguiSabarasa Entertainmentwww.sabarasa.com.ar
i think the problem happens when the resolution used by the game is less than the desktop resolution
I don''t think there is any way around it, you just have to put up with it. It might help if you used IDirectDraw::RestoreDisplayMode() at the end before you released your DirectDraw object.

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


sharewaregames.20m.com

quote:Original post by Quantum

i think the problem happens when the resolution used by the game is less than the desktop resolution


Can''t be.
I use 1024x768 all the time (On my desktop and in my apps) and it still happens.



- Goblineye Entertainment
The road to success is always under construction
Goblineye EntertainmentThe road to success is always under construction
Try calling your shutdown code from within a WM_CLOSE or WM_DESTROY message handler. I''m assuming that you''re shutting down after the message loop exits.
if you are using exclusive mode, you need to restore normal mode before destroying your ddraw object.

    pDD->SetCooperativeLevel(0, NORMAL); //dunno the excact syntax    


rid
I am calling the shutdown code from the WM_CLOSE message, and I''m also using RestoreDisplayMode(), but it doesn''t seems to work. I''ve inserted the SetCooperativeLevel(hwnd,DDSCL_NORMAL) code also, but it keeps doing the same.

I think that the problem isn''t in the shutdown of the program, but, instead, it is in the initialization of DirectX. While we are in fullscreen mode, some update messages are thrown to the other apps, and they check, lets say, GetSystemMetrics() or similar, and they resize themselves. There must be some way to solve this.

Despotismo AKA Javier Otaegui
Sabarasa Entertainment
www.sabarasa.com.ar
Despotismo AKA Javier OtaeguiSabarasa Entertainmentwww.sabarasa.com.ar
I believe you can safely ignore this. I''m fairly sure that this only happens during debug runs from msvc. If you do a build, close msvc, then run the actual .exe using windows this doesn''t happen.

I''m almost certain anyway

Just because the church was wrong doesn't mean Galileo wasn't a heritic.
It just means he was a heritic who was right.
Just because the church was wrong doesn't mean Galileo wasn't a heretic.It just means he was a heretic who was right.

This topic is closed to new replies.

Advertisement