public class ConvexPolyhedralRegion extends AbstractRegion
world| Constructor and Description |
|---|
ConvexPolyhedralRegion(ConvexPolyhedralRegion region)
Constructs an independent copy of the given region.
|
ConvexPolyhedralRegion(LocalWorld world)
Constructs an empty mesh, containing no vertices or triangles.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
addVertex(Vector vertex)
Add a vertex to the region.
|
void |
clear()
Clears the region, removing all vertices and triangles.
|
AbstractRegion |
clone() |
boolean |
contains(Vector pt)
Returns true based on whether the region contains the point.
|
void |
contract(Vector... changes)
Contract the region.
|
void |
expand(Vector... changes)
Expand the region.
|
Vector |
getCenter()
Get the center point of a region.
|
Vector |
getMaximumPoint()
Get the upper point of a region.
|
Vector |
getMinimumPoint()
Get the lower point of a region.
|
Collection<Triangle> |
getTriangles() |
Collection<Vector> |
getVertices() |
boolean |
isDefined() |
void |
shift(Vector change)
Shift the region.
|
getArea, getChunkCubes, getChunks, getHeight, getLength, getWidth, getWorld, iterator, polygonize, setWorldpublic ConvexPolyhedralRegion(LocalWorld world)
world - public ConvexPolyhedralRegion(ConvexPolyhedralRegion region)
world - public void clear()
public boolean addVertex(Vector vertex)
vertex - public boolean isDefined()
public Vector getMinimumPoint()
Regionpublic Vector getMaximumPoint()
Regionpublic Vector getCenter()
RegiongetCenter in interface RegiongetCenter in class AbstractRegionpublic void expand(Vector... changes) throws RegionOperationException
Regionchanges - array/arguments with multiple related changesRegionOperationExceptionpublic void contract(Vector... changes) throws RegionOperationException
Regionchanges - array/arguments with multiple related changesRegionOperationExceptionpublic void shift(Vector change) throws RegionOperationException
Regionshift in interface Regionshift in class AbstractRegionRegionOperationExceptionpublic boolean contains(Vector pt)
Regionpublic Collection<Vector> getVertices()
public Collection<Triangle> getTriangles()
public AbstractRegion clone()
clone in interface Regionclone in class AbstractRegionCopyright © 2010-2014. All Rights Reserved.