• Advertisement
Sign in to follow this  

Losing Device while minimized not working - HELP

This topic is 4339 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

I spent many nights ripping out my hair trying to figure out why my engine does not lose the state when i minimize the window. Here is my code to check:
hr = D3DDevice->Present(NULL, NULL, NULL, NULL);

// Handle losing a device
if (hr == D3DERR_DEVICELOST)
{
	DeviceLost = true;
}else{
	Render();
}

hr never equals D3DERR_DEVICELOST for some reason, i cant figure it out. can you guys spare som insight on this???

Share this post


Link to post
Share on other sites
Advertisement
If you are not in full screen mode minimize the window will not cause a lost device. You should process the windows messages that tell you that your app is minimized.

Share this post


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

  • Advertisement