use better tolerance, instead of hard-coded 0.0001 inside the btMultiSphereShape supporting vector implementation.
Thanks to Phil Knight for reporting and fixing this issue (it could lead to failing collisions under certain conditions).
This commit is contained in:
1 parent
126f46cb99
commit
7ef4eab189
1 file changed
+1
-1
@@ -47,7 +47,7 @@ btMultiSphereShape::btMultiSphereShape (const btVector3& inertiaHalfExtents,cons
|
||||
|
||||
btVector3 vec = vec0;
|
||||
btScalar lenSqr = vec.length2();
|
||||
if (lenSqr < btScalar(0.0001))
|
||||
if (lenSqr < (SIMD_EPSILON*SIMD_EPSILON))
|
||||
{
|
||||
vec.setValue(1,0,0);
|
||||
} else
|
||||
|
||||
Reference in new issue
Block a user