Jump to content
  • Advertisement
Sign in to follow this  
Specchum

SDL - window switching.

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

What is the recommended way to handle a task switching/minimize/restore event under windows when using SDL under OpenGL? I ask because when my game is running in full screen, task switching causes it to minimize to task bar but there's no way to restore it (or at least I can't figure out how). Secondly, when in windowed mode, minimizing and restore brings the game back but some of the textures are lost. I know I have to reload the textures in such cases but how do I capture the restore event?

Share this post


Link to post
Share on other sites
Advertisement
I believe it's the blit call that returns a special error value when you need to restore that surface.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Try catching a SDL_ActiveEvent. See http://www.libsdl.org/cgi/docwiki.cgi/SDL_5fActiveEvent

Share this post


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

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!