BVNodeBase encodes the tree structure for BVH. More...
#include <hpp/fcl/BV/BV_node.h>
Public Member Functions | |
bool | isLeaf () const |
Whether current node is a leaf node (i.e. contains a primitive index. | |
int | primitiveId () const |
Return the primitive index. The index is referred to the original data (i.e. vertices or tri_indices) in BVHModel. | |
int | leftChild () const |
Return the index of the first child. The index is referred to the bounding volume array (i.e. bvs) in BVHModel. | |
int | rightChild () const |
Return the index of the second child. The index is referred to the bounding volume array (i.e. bvs) in BVHModel. | |
Public Attributes | |
int | first_child |
An index for first child node or primitive If the value is positive, it is the index of the first child bv node If the value is negative, it is -(primitive index + 1) Zero is not used. | |
int | first_primitive |
The start id the primitive belonging to the current node. | |
int | num_primitives |
The number of primitives belonging to the current node. |
BVNodeBase encodes the tree structure for BVH.
bool fcl::BVNodeBase::isLeaf | ( | ) | const [inline] |
Whether current node is a leaf node (i.e. contains a primitive index.
References first_child.
int fcl::BVNodeBase::leftChild | ( | ) | const [inline] |
Return the index of the first child. The index is referred to the bounding volume array (i.e. bvs) in BVHModel.
References first_child.
int fcl::BVNodeBase::primitiveId | ( | ) | const [inline] |
Return the primitive index. The index is referred to the original data (i.e. vertices or tri_indices) in BVHModel.
References first_child.
Referenced by fcl::MeshCollisionTraversalNode< OBBRSS >::leafTesting(), fcl::MeshShapeCollisionTraversalNode< OBBRSS, S, NarrowPhaseSolver >::leafTesting(), fcl::MeshDistanceTraversalNode< OBBRSS >::leafTesting(), fcl::ShapeMeshCollisionTraversalNode< S, kIOS, NarrowPhaseSolver >::leafTesting(), fcl::MeshShapeDistanceTraversalNode< OBBRSS, S, NarrowPhaseSolver >::leafTesting(), and fcl::ShapeMeshDistanceTraversalNode< S, kIOS, NarrowPhaseSolver >::leafTesting().
int fcl::BVNodeBase::rightChild | ( | ) | const [inline] |
Return the index of the second child. The index is referred to the bounding volume array (i.e. bvs) in BVHModel.
References first_child.
An index for first child node or primitive If the value is positive, it is the index of the first child bv node If the value is negative, it is -(primitive index + 1) Zero is not used.
Referenced by isLeaf(), leftChild(), primitiveId(), and rightChild().
The start id the primitive belonging to the current node.
The index is referred to the primitive_indices in BVHModel and from that we can obtain the primitive's index in original data indirectly.
Referenced by fcl::BVHExpand().
The number of primitives belonging to the current node.
Referenced by fcl::BVHExpand().