[cairo] Stroke and Fill

Jose O Gonzalez jose_ogp at juno.com
Thu Sep 2 23:32:10 PDT 2004



On Thu, 02 Sep 2004 11:41:13 -0400 Carl Worth writes:
> On Thu, 2 Sep 2004 08:09:08 -0400, Jose O Gonzalez wrote: 
> > 	In fact, it seems to me that with any such set of
> > intermediate steps, it's going to be very difficult to do this
> > (in the generality I'm describing here, ie. with independent 
> stroke
> > and fill alphas and/or independent stroke and fill compositing 
> ops),
> > unless at some point one somehow manages to 'subtract' the stroke
> > region from the fill region.
> 
> Fortunately, you can do exactly that. Owen Talyor already wrote one
> example in cairo-demo/X11/caior-knockout.c that uses an intermediate
> surface and "subtracts" a group of three circles from another. The 
> key
> is to use other compositing operators than the default
> CAIRO_OPERATOR_OVER. Owen achieves the subtraction with
> CAIRO_OPERATOR_OUT_REVERSE.
> 
> As you can see, these operators provide much more general 
> manipulations
> than just subtracting a stroke from a fill.
> 
	Ah, well that does indeed make things quite sensible.
Thanks again.

		jose.




More information about the cairo mailing list