Jump to content
  • Advertisement
Sign in to follow this  
NukeCorr

How to fade out

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

How can I fade out to black or white when I am using C++ and SDL. Or is it even possible, is it also possible change sprites' opacity?

Share this post


Link to post
Share on other sites
Advertisement
To fade in/out the whole screen just render a black quad over the top of everything and cycle it's alpha from opaque -> transparent (fade in) or transparent -> opaque (fade out).

To fade in/out a sprite/object cycle that object's alpha from transparent -> opaque (fade in) or the reverse (fade out)

-me

Share this post


Link to post
Share on other sites
Look into per-surface alpha (as opposed to per-pixel alpha).

Be careful with alpha blending and hardware surfaces. As a rule of thumb, if you are using alpha blending you should only use software surfaces.

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.

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!