public class RegionBSPTree2S extends AbstractRegionBSPTree<Point2S,RegionBSPTree2S.RegionNode2S> implements BoundarySource2S
| Modifier and Type | Class and Description |
|---|---|
static class |
RegionBSPTree2S.RegionNode2S
BSP tree node for two dimensional spherical space.
|
AbstractRegionBSPTree.AbstractRegionNode<P extends Point<P>,N extends AbstractRegionBSPTree.AbstractRegionNode<P,N>>, AbstractRegionBSPTree.BoundaryProjector<P extends Point<P>,N extends AbstractRegionBSPTree.AbstractRegionNode<P,N>>, AbstractRegionBSPTree.RegionSizeProperties<P extends Point<P>>AbstractBSPTree.AbstractNode<P extends Point<P>,N extends AbstractBSPTree.AbstractNode<P,N>>, AbstractBSPTree.SubtreeInitializer<N extends AbstractBSPTree.AbstractNode<?,?>>BSPTree.FindNodeCutRule, BSPTree.Node<P extends Point<P>,N extends BSPTree.Node<P,N>>| Constructor and Description |
|---|
RegionBSPTree2S()
Create a new, empty instance.
|
RegionBSPTree2S(boolean full)
Create a new region.
|
| Modifier and Type | Method and Description |
|---|---|
Iterable<GreatArc> |
boundaries() |
Stream<GreatArc> |
boundaryStream() |
protected AbstractRegionBSPTree.RegionSizeProperties<Point2S> |
computeRegionSizeProperties() |
RegionBSPTree2S |
copy()
Return a deep copy of this instance.
|
protected RegionBSPTree2S.RegionNode2S |
createNode() |
static RegionBSPTree2S |
empty()
Return a new, empty BSP tree.
|
static RegionBSPTree2S |
from(Iterable<GreatArc> boundaries)
Construct a new tree from the given boundaries.
|
static RegionBSPTree2S |
from(Iterable<GreatArc> boundaries,
boolean full)
Construct a new tree from the given boundaries.
|
static RegionBSPTree2S |
full()
Return a new, full BSP tree.
|
List<GreatArc> |
getBoundaries() |
List<GreatArcPath> |
getBoundaryPaths()
Get the boundary of the region as a list of connected great arc paths.
|
protected void |
invalidate() |
Point2S |
project(Point2S pt) |
Split<RegionBSPTree2S> |
split(Hyperplane<Point2S> splitter) |
List<ConvexArea2S> |
toConvex()
Return a list of
ConvexArea2Ss representing the same region
as this instance. |
RegionBSPTree2S |
toTree()
Return the current instance.
|
classify, complement, complement, condense, copyNodeProperties, createBoundaryIterable, createBoundaryList, difference, difference, getBoundarySize, getCentroid, getRegionSizeProperties, getSize, getSubtreeInitializer, insert, insert, insert, insert, insert, insert, insert, insert, intersection, intersection, isEmpty, isFull, setEmpty, setFull, split, union, union, xor, xoraccept, accept, copy, copyNode, copySubtree, count, cutNode, extract, extractParentPath, findNode, findNode, getRoot, getVersion, height, importSubtree, insert, nodes, removeNodeCut, setNodeCut, setRoot, splitIntoTrees, splitSubtree, swapsInsideOutside, toString, transform, treeString, treeString, trimToNodeclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitof, of, toListisFinite, isInfinitepublic RegionBSPTree2S()
public RegionBSPTree2S(boolean full)
full is true, then the region will
represent the entire 2-sphere. Otherwise, it will be empty.full - whether or not the region should contain the entire
2-sphere or be emptypublic RegionBSPTree2S copy()
AbstractBSPTree.copy(org.apache.commons.geometry.core.partitioning.bsp.BSPTree)public Iterable<GreatArc> boundaries()
boundaries in class AbstractRegionBSPTree<Point2S,RegionBSPTree2S.RegionNode2S>public Stream<GreatArc> boundaryStream()
boundaryStream in interface BoundarySource<GreatArc>public List<GreatArc> getBoundaries()
getBoundaries in class AbstractRegionBSPTree<Point2S,RegionBSPTree2S.RegionNode2S>public List<GreatArcPath> getBoundaryPaths()
public List<ConvexArea2S> toConvex()
ConvexArea2Ss representing the same region
as this instance. One convex area is returned for each interior leaf
node in the tree.public Split<RegionBSPTree2S> split(Hyperplane<Point2S> splitter)
split in interface Splittable<Point2S,HyperplaneBoundedRegion<Point2S>>public Point2S project(Point2S pt)
project in interface Region<Point2S>project in class AbstractRegionBSPTree<Point2S,RegionBSPTree2S.RegionNode2S>public RegionBSPTree2S toTree()
toTree in interface BoundarySource2Sprotected AbstractRegionBSPTree.RegionSizeProperties<Point2S> computeRegionSizeProperties()
computeRegionSizeProperties in class AbstractRegionBSPTree<Point2S,RegionBSPTree2S.RegionNode2S>protected RegionBSPTree2S.RegionNode2S createNode()
createNode in class AbstractBSPTree<Point2S,RegionBSPTree2S.RegionNode2S>protected void invalidate()
invalidate in class AbstractRegionBSPTree<Point2S,RegionBSPTree2S.RegionNode2S>public static RegionBSPTree2S empty()
public static RegionBSPTree2S full()
public static RegionBSPTree2S from(Iterable<GreatArc> boundaries)
boundaries - boundaries to construct the tree fromfrom(Iterable, boolean)public static RegionBSPTree2S from(Iterable<GreatArc> boundaries, boolean full)
full is true, then
the initial tree before boundary insertion contains the entire space. Otherwise,
it is empty.boundaries - boundaries to construct the tree fromfull - if true, the initial tree will contain the entire spaceCopyright © 2016–2021 The Apache Software Foundation. All rights reserved.