swap m_x and m_q in softbody to align with rendering convention

This commit is contained in:
Xuchen Han
2019-08-26 16:18:56 -07:00
parent 7c39052163
commit e73f70efa2
6 changed files with 16 additions and 16 deletions

View File

@@ -2819,9 +2819,9 @@ void btSoftBody::initializeDmInverse()
for (int i = 0; i < m_tetras.size(); ++i)
{
Tetra &t = m_tetras[i];
btVector3 c1 = t.m_n[1]->m_q - t.m_n[0]->m_q;
btVector3 c2 = t.m_n[2]->m_q - t.m_n[0]->m_q;
btVector3 c3 = t.m_n[3]->m_q - t.m_n[0]->m_q;
btVector3 c1 = t.m_n[1]->m_x - t.m_n[0]->m_x;
btVector3 c2 = t.m_n[2]->m_x - t.m_n[0]->m_x;
btVector3 c3 = t.m_n[3]->m_x - t.m_n[0]->m_x;
btMatrix3x3 Dm(c1.getX(), c2.getX(), c3.getX(),
c1.getY(), c2.getY(), c3.getY(),
c1.getZ(), c2.getZ(), c3.getZ());