Sorry I forgot mailing lists in CC !

Hi Jim,

Did you start looking at early rejection of segments (clipping) ?

On my side, I looked at the Stroker class and I figured out why it
generates so many segments (4M) for my 800k spiral: mitter join are
generated with many intermediate segments.

I wrote the StrokerTest class to illustrate this issue : it uses the
createStrokedShape() to illustrate / check what the renderer does
(stroking, dashing, culling).
Here is the ductus / pisces output with cap = CAP_BUTT (no extra cap
decoration) and join = MITTER_JOIN: you can see mitter joins are made with
several segments: 2 extra segment per join.


I started understanding and hacking the drawJoin() method = some quick &
dirty hacks to remove the intermediate point and use the intersection point
instead.

- Marlin without collinear Simplifier:



- Marlin with collinear Simplifier: it removes collinear segments:


To conclude, it is promising (many tests with curves remain) but I would
prefer avoiding generating such extra segments in the Stroker / Dasher as
early as possible ... but it seems more tricky !

PS: Cap decoration have the same issue: it generates 3 extra segments for
CAP_SQUARE, but the collinear simplifier eliminate superfluous segments.


Does anybody have any idea / opinion ?

Is there any reason to generate these intermediate segments (winding rule,
...) as ductus / pisces does ?

Does it seem possible to remove them definitely for the marlin renderer at
least ?


Cheers,
Laurent

Reply via email to