←back to thread

168 points mindbrix | 3 comments | | HN request time: 0.746s | source
Show context
mindbrix ◴[] No.45090554[source]
I've been working on this problem on and off for over 10 years.

AMA ;-)

replies(10): >>45135183 #>>45135904 #>>45136129 #>>45136397 #>>45136649 #>>45137089 #>>45137395 #>>45138275 #>>45138939 #>>45140931 #
1. geokon ◴[] No.45137089[source]
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?

replies(1): >>45137220 #
2. mindbrix ◴[] No.45137220[source]
The Rasterizer algorithm handles self-intersecting paths without issue. Removing them requires expensive and complex computation geometry.
replies(1): >>45139730 #
3. ssp ◴[] No.45139730[source]
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?