EXA component alpha

Eric Anholt eta at lclark.edu
Fri Jan 6 12:32:47 PST 2006


On Thu, 2006-01-05 at 13:10 +0100, Thomas Hellström wrote:
> Hi!
> 
> While working with via composite acceleration I've come across 
> situations where the src picture is ABGR8888 and the mask is ARGB8888.
> 
> Is the four component mask intended to be used as component alpha or 
> should the RGB data be ignored and the A channel be used as alpha for 
> all channels on the source?

If the component alpha flag on the mask (pMask->componentaAlpha) is set,
then you need to do component alpha blending with it.  If you could
manage to do that with via hardware in one pass, congratulations, you've
got features that aren't in radeons, r128, 3dfx, sis, mga, etc.

If the component alpha flag isn't set, then you have to pull out the A
channel of the ARGB mask and use that like you would have used it for A8
mask.  I've heard that gnome uses this to have render do
premultiplication.  Take your ARGB8888 unpremultiplied data, create one
PICT_x8r8g8b8 picture for it ("src"), one PICT_a8r8g8b8 picture for it
("mask") and composite.  We've actually got fast paths in fb code for
this :)

-- 
Eric Anholt                                     eta at lclark.edu
http://people.freebsd.org/~anholt/              anholt at FreeBSD.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 187 bytes
Desc: This is a digitally signed message part
URL: <http://lists.x.org/archives/xorg/attachments/20060106/bde95a24/attachment.pgp>


More information about the xorg mailing list