Archived

This topic is now archived and is closed to further replies.

3dModelMan

Alt+Tabbing fullscreen D3D

Recommended Posts

3dModelMan    204
It''s an age old question! Just how much work should I do to make my app alt+tab proof? My texture manager is now capable of restoring, and reloading any lost textures, and I check that the primary surface, the back buffer and the z-buffer are not lost at the beginning of every frame, yet I still haven''t cracked it. The program doesn''t crash, but I just get a black screen when I return to it. I''ll go and experiment with it for a while, but any help in the meantime would be much appreciated. Cheers Matt

Share this post


Link to post
Share on other sites
SikCiv    122
I had the same problem, you need to use ->reset to restore the screen. If the app returns in a different video mode, you will get a black screen and D3DERR_NOT_RESET errors from your draw and flip functions. Refer to the Donuts3D sample app within the SDK to see how ->Reset should be implemented.

  Downloads:  ZeroOne Realm

Share this post


Link to post
Share on other sites
Guest Anonymous Poster   
Guest Anonymous Poster
find more info in the DirectX SDK on:

IDirect3DDevice8::TestCooperativeLevel()

and

IDirect3DDevice8::Reset();

Share this post


Link to post
Share on other sites
stefu    120
And after a succesfull Reset() call remember to set render states. Otherwise it''ll still show you black screen.

Share this post


Link to post
Share on other sites
3dModelMan    204
Ok, thanks. I''ll try Reset().

I tried implementing a WaitMessage loop, and testing the coop level, but for some strange reason it returns DDER_NOEXCLUSIVEMODE 3 or 4 times before continuing.

Thanks again!

- Matt

Share this post


Link to post
Share on other sites