Constructor creates new instance of polygon. With no arguments new polygon is empty.
Constructor accepts as argument array that define loop of shapes
or array of arrays in case of multi polygon
Loop may be defined in different ways:
Add new face to polygon. Returns added face
Rest...args: new face may be create with one of the following ways:
Returns true if polygon contains shape: no point of shape lay outside of the polygon, false otherwise
test shape
Delete existing face from polygon
Face to be deleted
Return new polygon rotated by given angle around given point If point omitted, rotate around origin (0,0) Positive value of angle defines rotation counterclockwise, negative - clockwise
rotation angle in radians
rotation center, default is (0,0)
new rotated polygon
Class representing a polygon.
Polygon is a multipolygon comprised from a set of [faces]Face.
Face, in turn, is a closed loop of [edges]Edge, where edge may be segment or circular arc