[cairo] perf: long dashed lines
Jeff Muizelaar
jeff at infidigm.net
Thu Jan 31 17:06:54 PST 2008
On Thu, Jan 31, 2008 at 12:07:58PM -0800, Vladimir Vukicevic wrote:
> Any thoughts on where we could optimize this? The complex thing seems
> to be in making sure that the dash pattern starts at the right point
> when the path is visible again.
I guess you could just check in _cairo_stroker_line_to_dashed whether
you were sufficiently outside of the clip and then switch to just
iterating through the dash array till you're back inside. That should
eliminate the compute_face overhead. It's certainly doable, however, it
would almost certainly make the code messier.
I've been thinking about adding a stroking implementation that produces
polygons instead of trapezoids so that they could be consumed by a
generic polygon rasterizer. I'll try to take this case into account
if/when I ever get around to it.
Out of curiosity, in what situation are you getting these long dashed lines?
-Jeff
More information about the cairo
mailing list