In this PR we aim to create a Polygon ShapeKind.
To check for any intersection between a Ray and the polygon we divide it in triangles and check the hit with them.
Thing to do:
Find the correct way to pass the vertices of each polygon.
Find how to safely and efficiently store the triangles.
Find how to avoid cycling over a polygon triangles, maybe using a little BVHTree (if convenient).
Update examples of Cornell box with Polygons as squared walls.
In this PR we aim to create a Polygon
ShapeKind
. To check for any intersection between aRay
and the polygon we divide it in triangles and check the hit with them.Thing to do: