OBBTreeNode Class Reference

This class represents a node in the Oriented Bounding Box Tree for a TriangleMesh. More...

#include <ContactGeometry.h>

List of all members.

Public Member Functions

 OBBTreeNode (const OBBTreeNodeImpl &impl)
const OrientedBoundingBoxgetBounds () const
 Get the OrientedBoundingBox which encloses all triangles in this node or its children.
bool isLeafNode () const
 Get whether this is a leaf node.
const OBBTreeNode getFirstChildNode () const
 Get the first child node.
const OBBTreeNode getSecondChildNode () const
 Get the second child node.
const std::vector< int > & getTriangles () const
 Get the indices of all triangles contained in this node.
int getNumTriangles () const
 Get the number of triangles inside this node.

Detailed Description

This class represents a node in the Oriented Bounding Box Tree for a TriangleMesh.

Each node has an OrientedBoundingBox that fully encloses all triangles contained within it or its children. This is a binary tree: each non-leaf node has two children. Triangles are stored only in the leaf nodes.


Constructor & Destructor Documentation

OBBTreeNode ( const OBBTreeNodeImpl impl  ) 

Member Function Documentation

const OrientedBoundingBox& getBounds (  )  const

Get the OrientedBoundingBox which encloses all triangles in this node or its children.

const OBBTreeNode getFirstChildNode (  )  const

Get the first child node.

Calling this on a leaf node will produce an exception.

int getNumTriangles (  )  const

Get the number of triangles inside this node.

If this is not a leaf node, this is the total number of triangles contained by all children of this node.

const OBBTreeNode getSecondChildNode (  )  const

Get the second child node.

Calling this on a leaf node will produce an exception.

const std::vector<int>& getTriangles (  )  const

Get the indices of all triangles contained in this node.

Calling this on a non-leaf node will produce an exception.

bool isLeafNode (  )  const

Get whether this is a leaf node.


The documentation for this class was generated from the following file:

Generated on Wed Dec 30 11:05:14 2009 for SimTKcore by  doxygen 1.6.1