disable raycast accelerator in Bullet, for better sweep and prune performance comparison (Bullet SAP)
This commit is contained in:
@@ -349,18 +349,19 @@ BulletSAPCompleteBoxPruningTest::BulletSAPCompleteBoxPruningTest(int numBoxes,in
|
|||||||
|
|
||||||
int maxNumBoxes = numBoxes;
|
int maxNumBoxes = numBoxes;
|
||||||
m_isdbvt=false;
|
m_isdbvt=false;
|
||||||
|
bool disableRaycastAccelerator = true;
|
||||||
switch (method)
|
switch (method)
|
||||||
{
|
{
|
||||||
case 1:
|
case 1:
|
||||||
m_broadphase = new btAxisSweep3(aabbMin,aabbMax,maxNumBoxes);
|
m_broadphase = new btAxisSweep3(aabbMin,aabbMax,maxNumBoxes,0,disableRaycastAccelerator);
|
||||||
methodname = "btAxisSweep3";
|
methodname = "btAxisSweep3";
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
m_broadphase = new btAxisSweep3(aabbMin,aabbMax,maxNumBoxes,new btNullPairCache());
|
m_broadphase = new btAxisSweep3(aabbMin,aabbMax,maxNumBoxes,new btNullPairCache(),disableRaycastAccelerator);
|
||||||
methodname = "btAxisSweep3+btNullPairCache";
|
methodname = "btAxisSweep3+btNullPairCache";
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
m_broadphase = new btAxisSweep3(aabbMin,aabbMax,maxNumBoxes,new btSortedOverlappingPairCache());
|
m_broadphase = new btAxisSweep3(aabbMin,aabbMax,maxNumBoxes,new btSortedOverlappingPairCache(),disableRaycastAccelerator);
|
||||||
methodname = "btAxisSweep3+btSortedOverlappingPairCache";
|
methodname = "btAxisSweep3+btSortedOverlappingPairCache";
|
||||||
break;
|
break;
|
||||||
case 4:
|
case 4:
|
||||||
@@ -397,7 +398,7 @@ BulletSAPCompleteBoxPruningTest::BulletSAPCompleteBoxPruningTest(int numBoxes,in
|
|||||||
tmpAabbMin[2] = aabbMin[2] + k*(aabbMax[2]-aabbMin[2])/numP;
|
tmpAabbMin[2] = aabbMin[2] + k*(aabbMax[2]-aabbMin[2])/numP;
|
||||||
tmpAabbMax[2] = aabbMin[2] + (k+1)*(aabbMax[2]-aabbMin[2])/numP;
|
tmpAabbMax[2] = aabbMin[2] + (k+1)*(aabbMax[2]-aabbMin[2])/numP;
|
||||||
|
|
||||||
btAxisSweep3* childBp = new btAxisSweep3(tmpAabbMin,tmpAabbMax,maxNumBoxes,multiSap->getOverlappingPairCache());
|
btAxisSweep3* childBp = new btAxisSweep3(tmpAabbMin,tmpAabbMax,maxNumBoxes,multiSap->getOverlappingPairCache(),disableRaycastAccelerator);
|
||||||
multiSap->getBroadphaseArray().push_back(childBp);
|
multiSap->getBroadphaseArray().push_back(childBp);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user