public interface MPolygon2d extends Polygon2d
Modifier and Type | Method and Description |
---|---|
static MPolygon2d |
create(List<? extends Vector2d> vertices)
Creates a 2-dimensional polygon with the given vertices.
|
static MPolygon2d |
create(Polygon2d polygon)
Creates a 2-dimensional polygon with the contents deep copied from the given
polygon.
|
void |
resize(double resizeAmount)
Resizes this polygon by the given amount.
|
void |
simplify(double distance)
Simplifies this polygon by replacing closely grouped vertices with a
single vertex.
|
void |
translate(Vector2d translator)
Translates the polygon by the given vector in the XY-plane.
|
contains, contains, distance, distance, distance, distanceSquared, distanceSquared, distanceSquared, getArea, getBoundingRectangle, getCentroid, getEdgeIterator, getOrientedBoundingRectangle, getPerimeter, getVertexCount, getVertices, intersectEdges, intersects, isConvex, isCounterClockwise, shortestSegmentTo, toArea
forEach, iterator, spliterator
void simplify(double distance)
distance
- the distance used for checking if vertices are closely
groupedvoid resize(double resizeAmount)
resizeAmount
- the amount the polygon is resizedvoid translate(Vector2d translator)
translator
- the vector used for translationstatic MPolygon2d create(List<? extends Vector2d> vertices)
static MPolygon2d create(Polygon2d polygon)
Copyright © 2019 Solibri, Inc.. All rights reserved.