Disable overlapping pair debug variables behind the BT_DEBUG_COLLISION_PAIRS preprocessor definition.
This commit is contained in:
@@ -20,11 +20,12 @@ subject to the following restrictions:
|
|||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|
||||||
|
#ifdef BT_DEBUG_COLLISION_PAIRS
|
||||||
int gOverlappingSimplePairs = 0;
|
int gOverlappingSimplePairs = 0;
|
||||||
int gRemoveSimplePairs =0;
|
int gRemoveSimplePairs =0;
|
||||||
int gAddedSimplePairs =0;
|
int gAddedSimplePairs =0;
|
||||||
int gFindSimplePairs =0;
|
int gFindSimplePairs =0;
|
||||||
|
#endif //BT_DEBUG_COLLISION_PAIRS
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -61,7 +62,9 @@ void btHashedSimplePairCache::removeAllPairs()
|
|||||||
|
|
||||||
btSimplePair* btHashedSimplePairCache::findPair(int indexA, int indexB)
|
btSimplePair* btHashedSimplePairCache::findPair(int indexA, int indexB)
|
||||||
{
|
{
|
||||||
|
#ifdef BT_DEBUG_COLLISION_PAIRS
|
||||||
gFindSimplePairs++;
|
gFindSimplePairs++;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/*if (indexA > indexB)
|
/*if (indexA > indexB)
|
||||||
@@ -172,7 +175,9 @@ btSimplePair* btHashedSimplePairCache::internalAddPair(int indexA, int indexB)
|
|||||||
|
|
||||||
void* btHashedSimplePairCache::removeOverlappingPair(int indexA, int indexB)
|
void* btHashedSimplePairCache::removeOverlappingPair(int indexA, int indexB)
|
||||||
{
|
{
|
||||||
|
#ifdef BT_DEBUG_COLLISION_PAIRS
|
||||||
gRemoveSimplePairs++;
|
gRemoveSimplePairs++;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/*if (indexA > indexB)
|
/*if (indexA > indexB)
|
||||||
|
|||||||
@@ -43,12 +43,12 @@ struct btSimplePair
|
|||||||
typedef btAlignedObjectArray<btSimplePair> btSimplePairArray;
|
typedef btAlignedObjectArray<btSimplePair> btSimplePairArray;
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef BT_DEBUG_COLLISION_PAIRS
|
||||||
extern int gOverlappingSimplePairs;
|
extern int gOverlappingSimplePairs;
|
||||||
extern int gRemoveSimplePairs;
|
extern int gRemoveSimplePairs;
|
||||||
extern int gAddedSimplePairs;
|
extern int gAddedSimplePairs;
|
||||||
extern int gFindSimplePairs;
|
extern int gFindSimplePairs;
|
||||||
|
#endif //BT_DEBUG_COLLISION_PAIRS
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -75,7 +75,9 @@ public:
|
|||||||
// no new pair is created and the old one is returned.
|
// no new pair is created and the old one is returned.
|
||||||
virtual btSimplePair* addOverlappingPair(int indexA,int indexB)
|
virtual btSimplePair* addOverlappingPair(int indexA,int indexB)
|
||||||
{
|
{
|
||||||
|
#ifdef BT_DEBUG_COLLISION_PAIRS
|
||||||
gAddedSimplePairs++;
|
gAddedSimplePairs++;
|
||||||
|
#endif
|
||||||
|
|
||||||
return internalAddPair(indexA,indexB);
|
return internalAddPair(indexA,indexB);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user