Premultiplied alpha handle for driver

Huang, FrankR FrankR.Huang at amd.com
Thu Jun 3 19:20:58 PDT 2010


Morton,

	I still want to get understand to you CA operation on rendercheck.
	I see the code, the mask is not a simple PICT_A8 format, it is a 32 bit value, and each 8 bit alpha value for A, R, G, B?
	By the way, why the code need use XRenderChangePicture to modify the attribute of CPComponentAlpha. Is it used as to modify the Repeat attribute?
	And what is the aim of color_correct()?


Thanks,
Frank

-----Original Message-----
From: Jonathan Morton [mailto:jonathan.morton at movial.com] 
Sent: 2010年6月2日 2:02
To: Siarhei Siamashka
Cc: xorg-devel at lists.x.org; Huang, FrankR
Subject: Re: Premultiplied alpha handle for driver

On Tue, 2010-06-01 at 19:26 +0300, Siarhei Siamashka wrote:
> On Tuesday 01 June 2010, Jonathan Morton wrote:
> > On Mon, 2010-05-31 at 10:42 +0800, Huang, FrankR wrote:
> > > We know the premultiplied alpha will be used sometimes in blend. Is
> > > that used in the graphics driver?
> >
> > XRender always expects premultiplied alpha in images.  Your previous
> > example, with ARGB values of (100,255,0,0) is therefore an invalid pixel
> > vector, since the R channel is greater than the A channel.
> 
> This is not necessarily invalid. It's more like "additive blending" feature
> which is even used by some people:
> http://home.comcast.net/~tom_forsyth/blog.wiki.html#[[Premultiplied%20alpha]]

Well, that's a corner case, but I was trying to get a conceptual point
across.

-- 
------
From: Jonathan Morton
      jonathan.morton at movial.com






More information about the xorg-devel mailing list