The project is divided in three parts: 2D, 3D and C++.
Given a segment and a triangulated polygon, we need to understand if the segment "cuts" the polygon. If that is the case, we need to triangulate the cut figures. Images are worth many words:
In red we can see the segment, in blue the triangles that are cut, in gray the triangles that are near triangles that are cut. The red dot are the intersections between the segment and a triangle. The light blue lines are the triangulations of the triangels that are cut.
Given a polygon in the space and a parallelepiped, we need to understand if the polygon "cuts" the parallelepiped. If that is the case, we need to divide the cut sections in subsections. As before, images:
In red we have the polygon. In blue we have the cut tetrahedrons, in pink we have the tetrahedron that are near cut tetrahedrons. In yellow we have the polygons formed by the cut.
Just a translation of the 2D project in C++, with the same functionality.