Geometry::Primitive::Polygon - Closed shape with an arbitrary number of points.
Geometry::Primitive::Polygon represents a two dimensional figure bounded by a
series of points that represent a closed path.
my $poly = Geometry::Primitive::Polygon->new;
# No need to close the path, it's handled automatically
Set/Get the arrayref of points that make up this Polygon.
Creates a new Geometry::Primitive::Polygon
Area of this polygon. Assumes it is non-self-intersecting.
Add a point to this polygon.
Clears all points from this polygon.
Returns the number of points that bound this polygon.
Returns the point at the specified offset.
Get the end point. Provided for Shape role.
Get the start point. Provided for Shape role.
Scale this this polygon by the supplied amount.
Cory Watson <firstname.lastname@example.org>
COPYRIGHT & LICENSE¶
You can redistribute and/or modify this code under the same terms as Perl