com.bulletphysics.collision.broadphase
Class HashedOverlappingPairCache

java.lang.Object
  extended by com.bulletphysics.collision.broadphase.OverlappingPairCallback
      extended by com.bulletphysics.collision.broadphase.OverlappingPairCache
          extended by com.bulletphysics.collision.broadphase.HashedOverlappingPairCache

public class HashedOverlappingPairCache
extends OverlappingPairCache

Hash-space based OverlappingPairCache.


Constructor Summary
HashedOverlappingPairCache()
           
 
Method Summary
 BroadphasePair addOverlappingPair(BroadphaseProxy proxy0, BroadphaseProxy proxy1)
          Add a pair and return the new pair.
 void cleanOverlappingPair(BroadphasePair pair, Dispatcher dispatcher)
           
 void cleanProxyFromPairs(BroadphaseProxy proxy, Dispatcher dispatcher)
           
 BroadphasePair findPair(BroadphaseProxy proxy0, BroadphaseProxy proxy1)
           
 int getCount()
           
 int getNumOverlappingPairs()
           
 OverlapFilterCallback getOverlapFilterCallback()
           
 ObjectArrayList<BroadphasePair> getOverlappingPairArray()
           
 boolean hasDeferredRemoval()
           
 boolean needsBroadphaseCollision(BroadphaseProxy proxy0, BroadphaseProxy proxy1)
           
 void processAllOverlappingPairs(OverlapCallback callback, Dispatcher dispatcher)
           
 Object removeOverlappingPair(BroadphaseProxy proxy0, BroadphaseProxy proxy1, Dispatcher dispatcher)
           
 void removeOverlappingPairsContainingProxy(BroadphaseProxy proxy, Dispatcher dispatcher)
           
 void setInternalGhostPairCallback(OverlappingPairCallback ghostPairCallback)
           
 void setOverlapFilterCallback(OverlapFilterCallback overlapFilterCallback)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HashedOverlappingPairCache

public HashedOverlappingPairCache()
Method Detail

addOverlappingPair

public BroadphasePair addOverlappingPair(BroadphaseProxy proxy0,
                                         BroadphaseProxy proxy1)
Add a pair and return the new pair. If the pair already exists, no new pair is created and the old one is returned.

Specified by:
addOverlappingPair in class OverlappingPairCallback

removeOverlappingPair

public Object removeOverlappingPair(BroadphaseProxy proxy0,
                                    BroadphaseProxy proxy1,
                                    Dispatcher dispatcher)
Specified by:
removeOverlappingPair in class OverlappingPairCallback

needsBroadphaseCollision

public boolean needsBroadphaseCollision(BroadphaseProxy proxy0,
                                        BroadphaseProxy proxy1)

processAllOverlappingPairs

public void processAllOverlappingPairs(OverlapCallback callback,
                                       Dispatcher dispatcher)
Specified by:
processAllOverlappingPairs in class OverlappingPairCache

removeOverlappingPairsContainingProxy

public void removeOverlappingPairsContainingProxy(BroadphaseProxy proxy,
                                                  Dispatcher dispatcher)
Specified by:
removeOverlappingPairsContainingProxy in class OverlappingPairCallback

cleanProxyFromPairs

public void cleanProxyFromPairs(BroadphaseProxy proxy,
                                Dispatcher dispatcher)
Specified by:
cleanProxyFromPairs in class OverlappingPairCache

getOverlappingPairArray

public ObjectArrayList<BroadphasePair> getOverlappingPairArray()
Specified by:
getOverlappingPairArray in class OverlappingPairCache

cleanOverlappingPair

public void cleanOverlappingPair(BroadphasePair pair,
                                 Dispatcher dispatcher)
Specified by:
cleanOverlappingPair in class OverlappingPairCache

findPair

public BroadphasePair findPair(BroadphaseProxy proxy0,
                               BroadphaseProxy proxy1)
Specified by:
findPair in class OverlappingPairCache

getCount

public int getCount()

getOverlapFilterCallback

public OverlapFilterCallback getOverlapFilterCallback()

setOverlapFilterCallback

public void setOverlapFilterCallback(OverlapFilterCallback overlapFilterCallback)
Specified by:
setOverlapFilterCallback in class OverlappingPairCache

getNumOverlappingPairs

public int getNumOverlappingPairs()
Specified by:
getNumOverlappingPairs in class OverlappingPairCache

hasDeferredRemoval

public boolean hasDeferredRemoval()
Specified by:
hasDeferredRemoval in class OverlappingPairCache

setInternalGhostPairCallback

public void setInternalGhostPairCallback(OverlappingPairCallback ghostPairCallback)
Specified by:
setInternalGhostPairCallback in class OverlappingPairCache