2
\$\begingroup\$

When you clip a triangle against a plane, will you always get a triangle out? Are there perhaps cases where you don't get a triangle out of clipping it against a plane?

\$\endgroup\$

1 Answer 1

3
\$\begingroup\$

Nope. Clipping a triangle against a plane can result in a quadrilateral, which you will need to re-triangulate (unless you don't actually care about having triangles). In fact, it often results in a quad, since in most cases you get a quad on one side of the plane and a triangle on the other. You only get two triangles when the plane exactly intersects one vertex.

Consider the triangle below, which exists in the XY plane (you're looking "down the Z axis"). The blue line represents a YZ plane the triangle is clipped against, resulting in a tetrahedral shape when we consider the left half-space of the plane to be the "inside" space we care about. The pink line represents one possible re-triangulation of the quadrilateral.

enter image description here

\$\endgroup\$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .