|
![](/i/fill.gif) |
The point I was trying to make is this: All edges are shared between exactly
two triangles. The problem is, we don't know whether an edge intersection
should be counted as one intersection, two, or none. Consider the following
ugly 2-d art:
/
_ _ _ _ _ _ _ _ _/_ _ _
/\ \
/A \ B \
The dotted horizontal line is your ray. At A, it hits an edge that should
not be counted. At B, it hits an edge that should be counted. Each is
shared between exactly two faces.
The workaround in a situation like this is to cast another ray, parallel
to the first one but offset by a sufficiently small amount, through the
triangles in question. Count the intersections of that ray and use that
number to represent the intersections at the edge. The same thing works
for intersections at vertices, except that you have to make sure that you
don't hit any edges with the parallel ray.
Post a reply to this message
|
![](/i/fill.gif) |