Jump to content
  • Advertisement
Sign in to follow this  
LetsKillDave

Alpha Blending: To Pre or Not To Pre

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

Advertisement

I like to use pre-multiplied alpha in GC, but there is one thing I've had to be aware of, and that is alpha testing. With regular alpha, you can alpha-test and discard fragments with an alpha of 0 (fully transparent), saving a little bit of fill rate. However, there are usage cases with pre-mult alpha in which you want to draw those 0-alpha pixels (since it equates to an additive blend if RGB is non-0) but with alpha-testing they'll get discarded. Just a little something to be aware of if you find yourself having an issue.

Share this post


Link to post
Share on other sites

When would you do the pre multiplying?

If when authoring your texture, the transparent/background parts are black, then it's already done ;)

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!