• Advertisement
Sign in to follow this  

Screen saver crash...

This topic is 3936 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Can someone point me to a tut on dealing with screensaver device losses? Thanks much in advance, Devin

Share this post


Link to post
Share on other sites
Advertisement
As Endurion says, a screensaver is an executable Windows PE like any other. Moreover, nobody writes tutorials on lost devices. Read your API documentation to see why the device may not be behaving correctly. If you still can't work it out, post us some details and code and we'll see what we can do.

Admiral

Share this post


Link to post
Share on other sites
Most tutorials cover lost devices.

Basically, when the screen saver takes effect, your Direct3D calls will fail because the device is lost. Your program will not know about this failing until you call the Present method. The Present call will return an error indicating lost device.

When you detect a lost device, you have to reset or recreate your Direct3D resources (textures, vertex/index buffers, etc). The Direct3D device needs to be reset. For textures, if they are in managed memory, you don't have to worry about them. If they are in default memory, you will have to reload them.

Hope that helps. If you need more info, search for tutorials that talk about lost devices.

Share this post


Link to post
Share on other sites
Thanks, I've established code to do that, guess that's why I'm stumped. I'll look at it some more.

-Devin

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement