|
|
John VanSickle wrote:
> Try this:
>
> Find the planes that contain each triangle; if they are parallel (but
> not coincident), the triangles do not intersect.
>
> Find the line along which the planes intersect.
>
> Find the part of the line that lies within the first triangle. If the
> line lies out of the triangle, the triangles do not intersect.
>
> Find the part of the line that lies within the second triangle. If the
> line falls out of the triangle, the triangles do not intersect.
>
> If the two resulting line segments overlap, the triangles intersect.
> Otherwise, they don't.
>
> Hope this helps,
> John
Wow, sounds like it will take a long time to parse. (I actually want it to
test cubes for intersection, but the faces can be considered two triangles,
and if the faces don't intersect the cubes don't. For the bowl-full-o-cubes
thing...)
--
David Fontaine <dav### [at] faricynet> ICQ 55354965
Please visit my website: http://www.faricy.net/~davidf/
Post a reply to this message
|
|