Hi Djordje, you might also consider using Polyline.TriangulateClosedPolyline for this (example here).