Click or drag to resize
Ab4d.SharpEngine logo

TriangulatorTriangulate Method

Overload List
 NameDescription
Public methodStatic memberTriangulate(Vector2) Triangulate method triangulates the specified points and creates a list of triangle indices that define the polygon.
Public methodTriangulate(ListVector2, ListInt32) Triangulate method triangulates the polygons that were specified in the constructor and holes that were added by the AddHole(Vector2) method. It sets the triangulated positions (the outer polygons and holes are connected into a single polygon) and triangle indices that can be used to create a 3D mesh.
Public methodStatic memberTriangulate(Vector2, ListVector2, ListInt32) Triangulate method triangulates the polygons with holes and returns positions and triangle indices that can be used to create a 3D mesh. Shape with holes is represented by multiple arrays of positions that are defined by the polygons property. The holes are identified by the orientation of positions (clockwise or anti-clockwise) that is different from the orientation of positions in the outer polygons. The orientation of the outer polygons is defined by the orientation of the first polygon. The method returns a list of triangulated positions (the outer polygons and holes are connected into a single polygon) and a list of triangle indices that used to create a 3D mesh.
Top
See Also