Jump to content
  • Advertisement

Archived

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

Mr Cucumber

What is alpha?

This topic is 6926 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 hear about alpha all the time but I don''t know what it is. So could anyone please help me explain it and how to implement it in my D3D engine.

Share this post


Link to post
Share on other sites
Advertisement
I''m no D3D programmer and I don''t know how to use alpha in D3D. Alpha is a kind of a transparency value for each pixel/texel. If the alpha value is 0, the pixel is completely transparent, a high value alpha (255 with 8 bit alpha) means that the pixel is opaque. If the value is between 0 and 255, the color of the fragment is combined with the color of the object behind.

Visit our homepage: www.rarebyte.de.st

GA

Share this post


Link to post
Share on other sites
Alpha is what you release before your betas

"Paranoia is the belief in a hidden order behind the visible." - Anonymous

Share this post


Link to post
Share on other sites
Alpha is another componant that makes up a pixels final colour - you understand that each pixel may have a red, green and blue componant, well alpha is an extra componant that defines how transparent the pixel is - so you can tell the pixel to have maximum alpha, and it will be completely see-through.
Don''t know how to implement it in D3D, I''m an OpenGL man.

-Mezz

Share this post


Link to post
Share on other sites
quote:
Original post by CobraA1

Alpha is the first letter in the greek (or was it hebrew?) alphabet.


It''s greek.

Visit our homepage: www.rarebyte.de.st

GA

Share this post


Link to post
Share on other sites
If you''re Origin, Alpha is what you release to the customers and charge $59.99 for it.

Share this post


Link to post
Share on other sites
Per pixel the alpha is the "intensity" of the pixel.
In formula, maybe something like this:

O = old pixel
P = poly pixel (overlapping)
N = new pixel
A = alpha (range: 0..1)

N = O*(1-A) + P*A

Share this post


Link to post
Share on other sites
The formula can be simplified to:
s=source pixel (what you''re drawing)
d=dest pixel (you''re drawing onto)
a = 0 to 1 (0=no source 1=all source)

new pixel = a(s-d)+d

This lends itself to both:
1. assembly!
2. MMX optimiztion

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.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!