net.java.dev.joode.space.octtree
Class OctTree

java.lang.Object
  extended by net.java.dev.joode.space.octtree.OctTreeNode
      extended by net.java.dev.joode.space.octtree.OctTree
All Implemented Interfaces:
java.io.Serializable, SimState

public class OctTree
extends OctTreeNode

The root node of the BSPTree used by OctTreeSpace. If Geoms outside of the bounds of this space get added, a new layers get added automaticaly until also the new Geom is contained.

Author:
Arne Müller
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class net.java.dev.joode.space.octtree.OctTreeNode
OctTreeNode.SplitType
 
Field Summary
 
Fields inherited from class net.java.dev.joode.space.octtree.OctTreeNode
aabb, geoms, left, numGeoms, right, splitPos, splitted, type
 
Constructor Summary
OctTree()
          creates a new OctTree
 
Method Summary
 void add(Geom g)
          adds a Geom to this TreeNode
 
Methods inherited from class net.java.dev.joode.space.octtree.OctTreeNode
cloneState, collide, collide2, getAABB, getGeoms, getNumGeoms, iterator, remove
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OctTree

public OctTree()
creates a new OctTree

Method Detail

add

public void add(Geom g)
Description copied from class: OctTreeNode
adds a Geom to this TreeNode

Overrides:
add in class OctTreeNode
Parameters:
g - the Geom to add