Jump to content
  • Advertisement


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


fade in screen

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

Draw scene. Disable depth testing. Enable alpha blending. Draw a white rectangle over the entire screen, with a steadily decreasing alpha value. Disable blending. Enable depth test. When the alpha value reaches 0, your scene is completely visible; you can then stop drawing the rectangle. If you want to fade out again, do the same with an increasing alpha value.

Share this post

Link to post
Share on other sites
whoomp - there it is!

The only thing I would add is that it''s easier to draw the big white rectangle in 2D mode (glOrtho).

My city demo has code to combine 2D and 3D mode in the routine DoOrthoModeRendering(), I think there''s even code that draws a polygon commented out. Just wrap this with alpha blending as the other poster suggests and voila.

Hope this helps.

Love means nothing to a tennis player

My nothing-to-write-home-about OpenGL webpage. (please pardon the popups!)

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

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

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!