toSegments method
Converts this shape to path segments.
Implementation
@override
List<Segment> toSegments() {
final rst = <Segment>[];
rst.add(MoveSegment(end: Offset(points[0].dx, points[0].dy)));
for (var i = 1; i < points.length; i++) {
rst.add(LineSegment(end: Offset(points[i].dx, points[i].dy)));
}
rst.add(CloseSegment());
return rst;
}