Non-clipping clips(wasRe: [cairo] Alpha masks)
Carl Worth
cworth at redhat.com
Thu Jan 6 21:20:08 PST 2005
On Thu, 06 Jan 2005 19:07:37 -0500, Owen Taylor wrote:
> The intuitively expected definition of how the clip operates follows
> from that:
>
> ((src Op dest) In clip) Add (dest Out clip)
>
> [ src here would be 'src In mask' for Cairo ]
Excellent work Owen! I was on my way toward deriving that earlier when
I got distracted by the smell of smoldering wood. (My 2-year-old son
still has blocks for toys, but the toaster oven defaults to unplugged
now).
> It's slightly different for Saturate and the well behaved
> Conjoint/Disjoint operators.
We've already dropped conjoint/disjoint from the operators available
in cairo, so that's not a problem here.
> Question: What if you replaced the RENDER equation of
> '(src In mask) op Dest' with
> '((src Op dest) In mask) Add (dest Out mask)'
That's less obvious to me. I'll start by implementing the above for
clipping in cairo, then it should be easier to see if we want to push
a specification change down into RENDER.
-Carl
More information about the cairo
mailing list