Blender V2.61 - r43446
Public Member Functions | Protected Member Functions | Protected Attributes

btQuantizedBvhTree Class Reference

Basic Box tree structure. More...

#include <btGImpactQuantizedBvh.h>

List of all members.

Public Member Functions

 btQuantizedBvhTree ()
void build_tree (GIM_BVH_DATA_ARRAY &primitive_boxes)
 stackless build tree
SIMD_FORCE_INLINE void quantizePoint (unsigned short *quantizedpoint, const btVector3 &point) const
 stackless build tree
SIMD_FORCE_INLINE bool testQuantizedBoxOverlapp (int node_index, unsigned short *quantizedMin, unsigned short *quantizedMax) const
 stackless build tree
SIMD_FORCE_INLINE void clearNodes ()
 stackless build tree
SIMD_FORCE_INLINE int getNodeCount () const
 node count
SIMD_FORCE_INLINE bool isLeafNode (int nodeindex) const
 tells if the node is a leaf
SIMD_FORCE_INLINE int getNodeData (int nodeindex) const
 stackless build tree
SIMD_FORCE_INLINE void getNodeBound (int nodeindex, btAABB &bound) const
 stackless build tree
SIMD_FORCE_INLINE void setNodeBound (int nodeindex, const btAABB &bound)
 stackless build tree
SIMD_FORCE_INLINE int getLeftNode (int nodeindex) const
 stackless build tree
SIMD_FORCE_INLINE int getRightNode (int nodeindex) const
 stackless build tree
SIMD_FORCE_INLINE int getEscapeNodeIndex (int nodeindex) const
 stackless build tree
SIMD_FORCE_INLINE const
BT_QUANTIZED_BVH_NODE * 
get_node_pointer (int index=0) const
 stackless build tree

Protected Member Functions

void calc_quantization (GIM_BVH_DATA_ARRAY &primitive_boxes, btScalar boundMargin=btScalar(1.0))
int _sort_and_calc_splitting_index (GIM_BVH_DATA_ARRAY &primitive_boxes, int startIndex, int endIndex, int splitAxis)
int _calc_splitting_axis (GIM_BVH_DATA_ARRAY &primitive_boxes, int startIndex, int endIndex)
void _build_sub_tree (GIM_BVH_DATA_ARRAY &primitive_boxes, int startIndex, int endIndex)

Protected Attributes

int m_num_nodes
GIM_QUANTIZED_BVH_NODE_ARRAY m_node_array
btAABB m_global_bound
btVector3 m_bvhQuantization

Detailed Description

Basic Box tree structure.

Definition at line 105 of file btGImpactQuantizedBvh.h.


Constructor & Destructor Documentation

btQuantizedBvhTree::btQuantizedBvhTree ( ) [inline]

Definition at line 123 of file btGImpactQuantizedBvh.h.

References m_num_nodes.


Member Function Documentation

void btQuantizedBvhTree::_build_sub_tree ( GIM_BVH_DATA_ARRAY primitive_boxes,
int  startIndex,
int  endIndex 
) [protected]
int btQuantizedBvhTree::_calc_splitting_axis ( GIM_BVH_DATA_ARRAY primitive_boxes,
int  startIndex,
int  endIndex 
) [protected]

Definition at line 88 of file btGImpactQuantizedBvh.cpp.

References i.

Referenced by _build_sub_tree().

int btQuantizedBvhTree::_sort_and_calc_splitting_index ( GIM_BVH_DATA_ARRAY primitive_boxes,
int  startIndex,
int  endIndex,
int  splitAxis 
) [protected]

Definition at line 120 of file btGImpactQuantizedBvh.cpp.

References btAssert, i, and btAlignedObjectArray< T >::swap().

Referenced by _build_sub_tree().

void btQuantizedBvhTree::build_tree ( GIM_BVH_DATA_ARRAY primitive_boxes)

stackless build tree

prototype functions for box tree management

Definition at line 233 of file btGImpactQuantizedBvh.cpp.

References _build_sub_tree(), calc_quantization(), m_node_array, m_num_nodes, btAlignedObjectArray< T >::resize(), and btAlignedObjectArray< T >::size().

Referenced by btGImpactQuantizedBvh::buildSet().

void btQuantizedBvhTree::calc_quantization ( GIM_BVH_DATA_ARRAY primitive_boxes,
btScalar  boundMargin = btScalar(1.0) 
) [protected]
SIMD_FORCE_INLINE void btQuantizedBvhTree::clearNodes ( ) [inline]

stackless build tree

prototype functions for box tree management

Definition at line 146 of file btGImpactQuantizedBvh.h.

References btAlignedObjectArray< T >::clear(), m_node_array, and m_num_nodes.

SIMD_FORCE_INLINE const BT_QUANTIZED_BVH_NODE* btQuantizedBvhTree::get_node_pointer ( int  index = 0) const [inline]

stackless build tree

prototype functions for box tree management

Definition at line 211 of file btGImpactQuantizedBvh.h.

References m_node_array.

Referenced by btGImpactQuantizedBvh::get_node_pointer().

SIMD_FORCE_INLINE int btQuantizedBvhTree::getEscapeNodeIndex ( int  nodeindex) const [inline]

stackless build tree

prototype functions for box tree management

Definition at line 206 of file btGImpactQuantizedBvh.h.

References m_node_array.

Referenced by btGImpactQuantizedBvh::getEscapeNodeIndex().

SIMD_FORCE_INLINE int btQuantizedBvhTree::getLeftNode ( int  nodeindex) const [inline]

stackless build tree

prototype functions for box tree management

Definition at line 195 of file btGImpactQuantizedBvh.h.

Referenced by btGImpactQuantizedBvh::getLeftNode().

SIMD_FORCE_INLINE void btQuantizedBvhTree::getNodeBound ( int  nodeindex,
btAABB &  bound 
) const [inline]

stackless build tree

prototype functions for box tree management

Definition at line 169 of file btGImpactQuantizedBvh.h.

References bt_unquantize(), m_bvhQuantization, m_global_bound, and m_node_array.

Referenced by btGImpactQuantizedBvh::getNodeBound().

SIMD_FORCE_INLINE int btQuantizedBvhTree::getNodeCount ( ) const [inline]

node count

Definition at line 153 of file btGImpactQuantizedBvh.h.

References m_num_nodes.

Referenced by btGImpactQuantizedBvh::getNodeCount().

SIMD_FORCE_INLINE int btQuantizedBvhTree::getNodeData ( int  nodeindex) const [inline]

stackless build tree

prototype functions for box tree management

Definition at line 164 of file btGImpactQuantizedBvh.h.

References m_node_array.

Referenced by btGImpactQuantizedBvh::getNodeData().

SIMD_FORCE_INLINE int btQuantizedBvhTree::getRightNode ( int  nodeindex) const [inline]

stackless build tree

prototype functions for box tree management

Definition at line 200 of file btGImpactQuantizedBvh.h.

References isLeafNode(), and m_node_array.

Referenced by btGImpactQuantizedBvh::getRightNode().

SIMD_FORCE_INLINE bool btQuantizedBvhTree::isLeafNode ( int  nodeindex) const [inline]

tells if the node is a leaf

Definition at line 159 of file btGImpactQuantizedBvh.h.

References m_node_array.

Referenced by getRightNode(), and btGImpactQuantizedBvh::isLeafNode().

SIMD_FORCE_INLINE void btQuantizedBvhTree::quantizePoint ( unsigned short *  quantizedpoint,
const btVector3 &  point 
) const [inline]

stackless build tree

prototype functions for box tree management

Definition at line 132 of file btGImpactQuantizedBvh.h.

References bt_quantize_clamp(), m_bvhQuantization, and m_global_bound.

Referenced by btGImpactQuantizedBvh::boxQuery().

SIMD_FORCE_INLINE void btQuantizedBvhTree::setNodeBound ( int  nodeindex,
const btAABB &  bound 
) [inline]

stackless build tree

prototype functions for box tree management

Definition at line 180 of file btGImpactQuantizedBvh.h.

References bt_quantize_clamp(), m_bvhQuantization, m_global_bound, and m_node_array.

Referenced by _build_sub_tree(), and btGImpactQuantizedBvh::setNodeBound().

SIMD_FORCE_INLINE bool btQuantizedBvhTree::testQuantizedBoxOverlapp ( int  node_index,
unsigned short *  quantizedMin,
unsigned short *  quantizedMax 
) const [inline]

stackless build tree

prototype functions for box tree management

Definition at line 139 of file btGImpactQuantizedBvh.h.

References m_node_array.

Referenced by btGImpactQuantizedBvh::boxQuery().


Member Data Documentation


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