[cairo] Redoing SOURCE and CLEAR
Carl Worth
cworth at redhat.com
Wed Aug 17 11:11:17 PDT 2005
On Wed, 17 Aug 2005 11:45:19 -0400, Owen Taylor wrote:
> So, the proposal here is to logically divide the operators into
> 4 groups by what definition we use:
>
> OVER, ATOP, DEST, DEST_OVER, DEST_OUT, XOR, ADD
>
> All definitions equivalent
>
> SOURCE, CLEAR
>
> (mask IN clip) ? src OP dest : dest
>
> IN, OUT, DEST_IN, DEST_ATOP
>
> clip ? (src IN mask) OP dest : dest
>
> SATURATE
>
> (src IN mask IN clip) OP dest
Another proposal is to also implement IN, OUT, DEST_IN, and DEST_ATOP
with:
(mask IN clip) ? src OP dest : dest
which would make this the fundamental equation and leave only SATURATE
as an exception.
That's appealing as far as having consistent mathematical grounding
for the rendering equation.
It's not obvious to me what impact this change would have on usability
or learnability of the behavior of these four operators. I think there
are at least two pieces of evidence that would help in this decision:
1) Use cases for these operators. That is, English descriptions of
things that would like to be achieved, along with corresponding
cairo code using one model or the other.
2) Two images much like those that Owen previously attached, but
showing these 4 operators with both equations.
I believe Owen is working on #2 right now.
-Carl
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/cairo/attachments/20050817/bc354630/attachment.pgp
More information about the cairo
mailing list