[cairo] Summer of Code ideas

Jeff Muizelaar jeff at infidigm.net
Fri Mar 28 06:49:43 PDT 2008


On Fri, Mar 28, 2008 at 12:34:34AM -0400, James Cloos wrote:
> >>>>> "Jeff" == Jeff Muizelaar <jeff at infidigm.net> writes:
> 
> Jeff> I haven't come across a 'textbook' algorithm for doing
> Jeff> stroke_to_path.  I've looked at a bunch different implementations
> Jeff> and there's a fair amount of variation among them. A lot of it
> Jeff> depends on the requirements for the result. Cairo's stroking code,
> Jeff> for example, produces trapezoids targeted at rasterization
> Jeff> backends.
> 
> Fontforge has an implementation that may be worth examining.  George
> splits outlining the stroke and removing overlaps into two separate
> functions.  Both end up using numerical methods to fit splines to the
> new path.  (I beleive I recall a comment in the code that he tried
> analytical algorithms but fell back to numerical because the latter had
> better performance and/or gave better results.)

I believe libart also does something similar to this.

-Jeff


More information about the cairo mailing list