btVoronoiSimplexSolver::inSimplex can return when first 'found=true' is set instead of going through all points, since found is never set to false in any other condition.

PersistentManifold replaceContactPoint set the same values for m_appliedImpluse; remove redunant set.
This commit is contained in:
d3x0r
2015-11-08 10:22:02 -08:00
parent e39afd06b9
commit 99acea9594
2 changed files with 3 additions and 4 deletions

View File

@@ -196,10 +196,6 @@ public:
m_pointCache[insertIndex].m_appliedImpulseLateral1 = appliedLateralImpulse1;
m_pointCache[insertIndex].m_appliedImpulseLateral2 = appliedLateralImpulse2;
m_pointCache[insertIndex].m_appliedImpulse = appliedImpulse;
m_pointCache[insertIndex].m_appliedImpulseLateral1 = appliedLateralImpulse1;
m_pointCache[insertIndex].m_appliedImpulseLateral2 = appliedLateralImpulse2;
m_pointCache[insertIndex].m_lifeTime = lifeTime;
#else

View File

@@ -294,7 +294,10 @@ bool btVoronoiSimplexSolver::inSimplex(const btVector3& w)
#else
if (m_simplexVectorW[i] == w)
#endif
{
found = true;
break;
}
}
//check in case lastW is already removed