split

fun split(shape: Shape, cutter: LineSegment): Pair<Shape, Shape>(source)

Splits a Shape into two separate Shapes from given LineSegment.

LineSegment doesn't necessarily need to cover the full length of the Shape, as it will be extended on both ends to ensure it splits the whole Shape.

Return

A pair containing two partial Shapes.


Splits a ShapeContour with another ShapeContour.

If there is no intersection, the original contour is returned.


Splits a ShapeContour with all other ShapeContour in a List.


Splits a ShapeContour with another ShapeContour.


Splits a ShapeContour with a List of ShapeContours.