add support for premade aabb in btStridingMeshInterface/btBvhTriangleMeshShape,

Thanks Roy Eltham, http://code.google.com/p/bullet/issues/detail?id=70
This commit is contained in:
erwin.coumans
2008-08-29 05:39:17 +00:00
parent 80f80df7e3
commit f655eff89f
5 changed files with 47 additions and 5 deletions

View File

@@ -30,7 +30,14 @@ m_ownsBvh(false)
#ifndef DISABLE_BVH
btVector3 bvhAabbMin,bvhAabbMax;
meshInterface->calculateAabbBruteForce(bvhAabbMin,bvhAabbMax);
if(meshInterface->hasPremadeAabb())
{
meshInterface->getPremadeAabb(&bvhAabbMin, &bvhAabbMax);
}
else
{
meshInterface->calculateAabbBruteForce(bvhAabbMin,bvhAabbMax);
}
if (buildBvh)
{