Bullet Collision Detection & Physics Library
|
The internal templace class btAxisSweep3Internal implements the sweep and prune broadphase. More...
#include <btAxisSweep3.h>
Classes | |
class | Edge |
class | Handle |
Public Member Functions | |
BT_DECLARE_ALIGNED_ALLOCATOR () | |
btAxisSweep3Internal (const btVector3 &worldAabbMin, const btVector3 &worldAabbMax, BP_FP_INT_TYPE handleMask, BP_FP_INT_TYPE handleSentinel, BP_FP_INT_TYPE maxHandles=16384, btOverlappingPairCache *pairCache=0, bool disableRaycastAccelerator=false) | |
virtual | ~btAxisSweep3Internal () |
BP_FP_INT_TYPE | getNumHandles () const |
virtual void | calculateOverlappingPairs (btDispatcher *dispatcher) |
calculateOverlappingPairs is optional: incremental algorithms (sweep and prune) might do it during the set aabb More... | |
BP_FP_INT_TYPE | addHandle (const btVector3 &aabbMin, const btVector3 &aabbMax, void *pOwner, short int collisionFilterGroup, short int collisionFilterMask, btDispatcher *dispatcher, void *multiSapProxy) |
void | removeHandle (BP_FP_INT_TYPE handle, btDispatcher *dispatcher) |
void | updateHandle (BP_FP_INT_TYPE handle, const btVector3 &aabbMin, const btVector3 &aabbMax, btDispatcher *dispatcher) |
Handle * | getHandle (BP_FP_INT_TYPE index) const |
virtual void | resetPool (btDispatcher *dispatcher) |
reset broadphase internal structures, to ensure determinism/reproducability More... | |
void | processAllOverlappingPairs (btOverlapCallback *callback) |
virtual btBroadphaseProxy * | createProxy (const btVector3 &aabbMin, const btVector3 &aabbMax, int shapeType, void *userPtr, short int collisionFilterGroup, short int collisionFilterMask, btDispatcher *dispatcher, void *multiSapProxy) |
virtual void | destroyProxy (btBroadphaseProxy *proxy, btDispatcher *dispatcher) |
virtual void | setAabb (btBroadphaseProxy *proxy, const btVector3 &aabbMin, const btVector3 &aabbMax, btDispatcher *dispatcher) |
virtual void | getAabb (btBroadphaseProxy *proxy, btVector3 &aabbMin, btVector3 &aabbMax) const |
virtual void | rayTest (const btVector3 &rayFrom, const btVector3 &rayTo, btBroadphaseRayCallback &rayCallback, const btVector3 &aabbMin=btVector3(0, 0, 0), const btVector3 &aabbMax=btVector3(0, 0, 0)) |
virtual void | aabbTest (const btVector3 &aabbMin, const btVector3 &aabbMax, btBroadphaseAabbCallback &callback) |
void | quantize (BP_FP_INT_TYPE *out, const btVector3 &point, int isMax) const |
void | unQuantize (btBroadphaseProxy *proxy, btVector3 &aabbMin, btVector3 &aabbMax) const |
unQuantize should be conservative: aabbMin/aabbMax should be larger then 'getAabb' result More... | |
bool | testAabbOverlap (btBroadphaseProxy *proxy0, btBroadphaseProxy *proxy1) |
btOverlappingPairCache * | getOverlappingPairCache () |
const btOverlappingPairCache * | getOverlappingPairCache () const |
void | setOverlappingPairUserCallback (btOverlappingPairCallback *pairCallback) |
const btOverlappingPairCallback * | getOverlappingPairUserCallback () const |
virtual void | getBroadphaseAabb (btVector3 &aabbMin, btVector3 &aabbMax) const |
getAabb returns the axis aligned bounding box in the 'global' coordinate frame will add some transform later More... | |
virtual void | printStats () |
Public Member Functions inherited from btBroadphaseInterface | |
virtual | ~btBroadphaseInterface () |
Protected Member Functions | |
BP_FP_INT_TYPE | allocHandle () |
void | freeHandle (BP_FP_INT_TYPE handle) |
bool | testOverlap2D (const Handle *pHandleA, const Handle *pHandleB, int axis0, int axis1) |
void | sortMinDown (int axis, BP_FP_INT_TYPE edge, btDispatcher *dispatcher, bool updateOverlaps) |
void | sortMinUp (int axis, BP_FP_INT_TYPE edge, btDispatcher *dispatcher, bool updateOverlaps) |
void | sortMaxDown (int axis, BP_FP_INT_TYPE edge, btDispatcher *dispatcher, bool updateOverlaps) |
void | sortMaxUp (int axis, BP_FP_INT_TYPE edge, btDispatcher *dispatcher, bool updateOverlaps) |
Protected Attributes | |
BP_FP_INT_TYPE | m_bpHandleMask |
BP_FP_INT_TYPE | m_handleSentinel |
btVector3 | m_worldAabbMin |
btVector3 | m_worldAabbMax |
btVector3 | m_quantize |
BP_FP_INT_TYPE | m_numHandles |
BP_FP_INT_TYPE | m_maxHandles |
Handle * | m_pHandles |
BP_FP_INT_TYPE | m_firstFreeHandle |
Edge * | m_pEdges [3] |
void * | m_pEdgesRawPtr [3] |
btOverlappingPairCache * | m_pairCache |
btOverlappingPairCallback * | m_userPairCallback |
btOverlappingPairCallback is an additional optional user callback for adding/removing overlapping pairs, similar interface to btOverlappingPairCache. More... | |
bool | m_ownsPairCache |
int | m_invalidPair |
btDbvtBroadphase * | m_raycastAccelerator |
additional dynamic aabb structure, used to accelerate ray cast queries. More... | |
btOverlappingPairCache * | m_nullPairCache |
The internal templace class btAxisSweep3Internal implements the sweep and prune broadphase.
It uses quantized integers to represent the begin and end points for each of the 3 axis. Dont use this class directly, use btAxisSweep3 or bt32BitAxisSweep3 instead.
Definition at line 36 of file btAxisSweep3.h.
btAxisSweep3Internal< BP_FP_INT_TYPE >::btAxisSweep3Internal | ( | const btVector3 & | worldAabbMin, |
const btVector3 & | worldAabbMax, | ||
BP_FP_INT_TYPE | handleMask, | ||
BP_FP_INT_TYPE | handleSentinel, | ||
BP_FP_INT_TYPE | maxHandles = 16384 , |
||
btOverlappingPairCache * | pairCache = 0 , |
||
bool | disableRaycastAccelerator = false |
||
) |
Definition at line 352 of file btAxisSweep3.h.
|
virtual |
Definition at line 435 of file btAxisSweep3.h.
|
virtual |
Implements btBroadphaseInterface.
Definition at line 291 of file btAxisSweep3.h.
BP_FP_INT_TYPE btAxisSweep3Internal< BP_FP_INT_TYPE >::addHandle | ( | const btVector3 & | aabbMin, |
const btVector3 & | aabbMax, | ||
void * | pOwner, | ||
short int | collisionFilterGroup, | ||
short int | collisionFilterMask, | ||
btDispatcher * | dispatcher, | ||
void * | multiSapProxy | ||
) |
Definition at line 505 of file btAxisSweep3.h.
|
protected |
Definition at line 481 of file btAxisSweep3.h.
btAxisSweep3Internal< BP_FP_INT_TYPE >::BT_DECLARE_ALIGNED_ALLOCATOR | ( | ) |
|
virtual |
calculateOverlappingPairs is optional: incremental algorithms (sweep and prune) might do it during the set aabb
important to use an AABB test that is consistent with the broadphase
if you don't like to skip the invalid pairs in the array, execute following code:
Implements btBroadphaseInterface.
Definition at line 636 of file btAxisSweep3.h.
|
virtual |
Implements btBroadphaseInterface.
Definition at line 231 of file btAxisSweep3.h.
|
virtual |
Implements btBroadphaseInterface.
Definition at line 249 of file btAxisSweep3.h.
|
protected |
Definition at line 493 of file btAxisSweep3.h.
|
virtual |
Implements btBroadphaseInterface.
Definition at line 318 of file btAxisSweep3.h.
|
inlinevirtual |
getAabb returns the axis aligned bounding box in the 'global' coordinate frame will add some transform later
Implements btBroadphaseInterface.
Definition at line 182 of file btAxisSweep3.h.
|
inline |
Definition at line 140 of file btAxisSweep3.h.
|
inline |
Definition at line 130 of file btAxisSweep3.h.
|
inlinevirtual |
Implements btBroadphaseInterface.
Definition at line 162 of file btAxisSweep3.h.
|
inlinevirtual |
Implements btBroadphaseInterface.
Definition at line 166 of file btAxisSweep3.h.
|
inline |
Definition at line 175 of file btAxisSweep3.h.
|
inlinevirtual |
Implements btBroadphaseInterface.
Definition at line 188 of file btAxisSweep3.h.
void btAxisSweep3Internal< BP_FP_INT_TYPE >::processAllOverlappingPairs | ( | btOverlapCallback * | callback | ) |
void btAxisSweep3Internal< BP_FP_INT_TYPE >::quantize | ( | BP_FP_INT_TYPE * | out, |
const btVector3 & | point, | ||
int | isMax | ||
) | const |
Definition at line 459 of file btAxisSweep3.h.
|
virtual |
Implements btBroadphaseInterface.
Definition at line 270 of file btAxisSweep3.h.
void btAxisSweep3Internal< BP_FP_INT_TYPE >::removeHandle | ( | BP_FP_INT_TYPE | handle, |
btDispatcher * | dispatcher | ||
) |
Definition at line 561 of file btAxisSweep3.h.
|
virtual |
reset broadphase internal structures, to ensure determinism/reproducability
Reimplemented from btBroadphaseInterface.
Definition at line 618 of file btAxisSweep3.h.
|
virtual |
Implements btBroadphaseInterface.
Definition at line 258 of file btAxisSweep3.h.
|
inline |
Definition at line 171 of file btAxisSweep3.h.
|
protected |
Definition at line 915 of file btAxisSweep3.h.
|
protected |
Definition at line 978 of file btAxisSweep3.h.
|
protected |
Definition at line 807 of file btAxisSweep3.h.
|
protected |
Definition at line 859 of file btAxisSweep3.h.
bool btAxisSweep3Internal< BP_FP_INT_TYPE >::testAabbOverlap | ( | btBroadphaseProxy * | proxy0, |
btBroadphaseProxy * | proxy1 | ||
) |
Definition at line 722 of file btAxisSweep3.h.
|
protected |
Definition at line 741 of file btAxisSweep3.h.
void btAxisSweep3Internal< BP_FP_INT_TYPE >::unQuantize | ( | btBroadphaseProxy * | proxy, |
btVector3 & | aabbMin, | ||
btVector3 & | aabbMax | ||
) | const |
unQuantize should be conservative: aabbMin/aabbMax should be larger then 'getAabb' result
Definition at line 327 of file btAxisSweep3.h.
void btAxisSweep3Internal< BP_FP_INT_TYPE >::updateHandle | ( | BP_FP_INT_TYPE | handle, |
const btVector3 & | aabbMin, | ||
const btVector3 & | aabbMax, | ||
btDispatcher * | dispatcher | ||
) |
Definition at line 756 of file btAxisSweep3.h.
|
protected |
Definition at line 40 of file btAxisSweep3.h.
|
protected |
Definition at line 83 of file btAxisSweep3.h.
|
protected |
Definition at line 41 of file btAxisSweep3.h.
|
protected |
Definition at line 95 of file btAxisSweep3.h.
|
protected |
Definition at line 80 of file btAxisSweep3.h.
|
protected |
Definition at line 100 of file btAxisSweep3.h.
|
protected |
Definition at line 79 of file btAxisSweep3.h.
|
protected |
Definition at line 93 of file btAxisSweep3.h.
|
protected |
Definition at line 88 of file btAxisSweep3.h.
|
protected |
Definition at line 85 of file btAxisSweep3.h.
|
protected |
Definition at line 86 of file btAxisSweep3.h.
|
protected |
Definition at line 81 of file btAxisSweep3.h.
|
protected |
Definition at line 77 of file btAxisSweep3.h.
|
protected |
additional dynamic aabb structure, used to accelerate ray cast queries.
can be disabled using a optional argument in the constructor
Definition at line 99 of file btAxisSweep3.h.
|
protected |
btOverlappingPairCallback is an additional optional user callback for adding/removing overlapping pairs, similar interface to btOverlappingPairCache.
Definition at line 91 of file btAxisSweep3.h.
|
protected |
Definition at line 75 of file btAxisSweep3.h.
|
protected |
Definition at line 74 of file btAxisSweep3.h.