fix double->float issue by cast, fixes issue #1510
fix possible out-of-bounds access in btMultiBody
This commit is contained in:
@@ -2533,10 +2533,10 @@ void PhysicsServerExample::drawUserDebugLines()
|
||||
optionFlag |= CommonGraphicsApp::eDrawText3D_OrtogonalFaceCamera;
|
||||
} else
|
||||
{
|
||||
orientation[0] = m_multiThreadedHelper->m_userDebugText[i].m_textOrientation[0];
|
||||
orientation[1] = m_multiThreadedHelper->m_userDebugText[i].m_textOrientation[1];
|
||||
orientation[2] = m_multiThreadedHelper->m_userDebugText[i].m_textOrientation[2];
|
||||
orientation[3] = m_multiThreadedHelper->m_userDebugText[i].m_textOrientation[3];
|
||||
orientation[0] = (float)m_multiThreadedHelper->m_userDebugText[i].m_textOrientation[0];
|
||||
orientation[1] = (float)m_multiThreadedHelper->m_userDebugText[i].m_textOrientation[1];
|
||||
orientation[2] = (float)m_multiThreadedHelper->m_userDebugText[i].m_textOrientation[2];
|
||||
orientation[3] = (float)m_multiThreadedHelper->m_userDebugText[i].m_textOrientation[3];
|
||||
optionFlag |= CommonGraphicsApp::eDrawText3D_TrueType;
|
||||
|
||||
}
|
||||
|
||||
@@ -749,7 +749,7 @@ void btMultiBody::computeAccelerationsArticulatedBodyAlgorithmMultiDof(btScalar
|
||||
// Temporary matrices/vectors -- use scratch space from caller
|
||||
// so that we don't have to keep reallocating every frame
|
||||
|
||||
scratch_r.resize(2*m_dofCount + 6); //multidof? ("Y"s use it and it is used to store qdd) => 2 x m_dofCount
|
||||
scratch_r.resize(2*m_dofCount + 7); //multidof? ("Y"s use it and it is used to store qdd) => 2 x m_dofCount
|
||||
scratch_v.resize(8*num_links + 6);
|
||||
scratch_m.resize(4*num_links + 4);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user