public void CloseContour() { CheckForOpenCurve3(); //vertexStorage.ClosePolygon(); if (vertexStorage.Count > polygonStartIndex) { vertexStorage.invert_polygon(polygonStartIndex); } polygonStartIndex = vertexStorage.Count; }