Hacker News new | ask | show | jobs
by geokon 283 days ago
You mentioned winding numbers in a couple of places

Wouldn't it make sense to do a "first pass" and eliminate paths that intersect themselves? (by splitting them into 2+ paths)

I never understood why these are supported in the SVG spec.

It seems like a pathological case. Once self-intersecting paths are eliminated the problem gets simpler.. no?

Or would a CPU pass be cheating?

1 comments

The Rasterizer algorithm handles self-intersecting paths without issue. Removing them requires expensive and complex computation geometry.
In a figure-8 path where the intersection is in the center of a pixel, does Rasterizer set that pixel to 0.5 or to 0?