Re: Alphablending
- From: "//\\\\o//\\\\annabee <Free" <Software>>
- Date: Sat, 29 Apr 2006 01:09:46 +0200
På Fri, 28 Apr 2006 23:57:25 +0200, skrev jukka@xxxxxxxxxxxx <jukka@xxxxxxxxxxxx>:
I am not sure what you reply to but guess it must be me.
No, it does not.
Does not what?
"source" and "destination" are concepts from OpenGL
and D3D ; the source is the incoming fragment and the "destination" is
the alpha value already in the render target.
Source and destination refers to background and foregound image in the docs I read.
The two that are blended into each other producing a 3rd image.
They are not some "concepts" from DirectX or OpenGL.
In this case we are
interested in combining the destination and source color using the
source alpha.
Yes, but that does not say a single thing.
What really happens is that the colors from a source pixel and a destination pixel are weighted, e.g. they are multiplied, each of the components against the alpha value.
say if the alpha is 0.5 and the RGB tripplet is ( 50, 100, 100 )
the result is ( 25, 50 50 )
The same is done to the background, except using (1.0-alfa)
so that if the background is (200, 100, 100) and the alpha is (1-0.5) still, then we end up with a background color of (100,50, 50)
So now that we have multiplied the alfa in, we ADD the colors together.
(25+100, 50+50, 50+50) = (125, 100, 100) and this is the color written to the target at that point. This is done for each pixel.
This pixel will contain half of the foreground, and half of the background.
Any other variation, will yield a mix between the two. Strong background, weak foreground, or visa versa.
There are other ways to combine the colors. But this is what is usually ment by alphablending. I should now, I read 10 papers at least saying the same.
.
- Follow-Ups:
- Re: Alphablending
- From: jukka@xxxxxxxxxxxx
- Re: Alphablending
- References:
- Alphablending
- From: //\\\\o//\\\\annabee <Free
- Re: Alphablending
- From: hutch--
- Re: Alphablending
- From: //\\\\o//\\\\annabee <Free
- Re: Alphablending
- From: Chewy509
- Re: Alphablending
- From: Dunny
- Re: Alphablending
- From: //\\\\o//\\\\annabee <Free
- Re: Alphablending
- From: silk.odyssey
- Re: Alphablending
- From: //\\\\o//\\\\annabee <Free
- Re: Alphablending
- From: Dunny
- Re: Alphablending
- From: //\\\\o//\\\\annabee <Free
- Re: Alphablending
- From: Dunny
- Re: Alphablending
- From: //\\\\o//\\\\annabee <Free
- Re: Alphablending
- From: //\\\\o//\\\\annabee <Free
- Re: Alphablending
- From: jukka@xxxxxxxxxxxx
- Re: Alphablending
- From: jukka@xxxxxxxxxxxx
- Re: Alphablending
- From: //\\\\o//\\\\annabee <Free
- Re: Alphablending
- From: jukka@xxxxxxxxxxxx
- Re: Alphablending
- From: jukka@xxxxxxxxxxxx
- Re: Alphablending
- From: //\\\\o//\\\\annabee <Free
- Re: Alphablending
- From: jukka@xxxxxxxxxxxx
- Alphablending
- Prev by Date: Re: Alphablending
- Next by Date: Re: Alphablending
- Previous by thread: Re: Alphablending
- Next by thread: Re: Alphablending
- Index(es):
Relevant Pages
|