From bc3b920995055a6e4bbe78b3a3d23ab1479293ee Mon Sep 17 00:00:00 2001 From: "erwin.coumans" Date: Thu, 11 Nov 2010 22:18:02 +0000 Subject: [PATCH] clarified the comments for set/getting of an OpenGL submatrix Thanks to Mihail Isakov, see Issue 452 Fix sleeping/deactivation issue with kinematic objects, see Issue 442 --- .../CollisionDispatch/btSimulationIslandManager.cpp | 6 +++--- src/LinearMath/btMatrix3x3.h | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/BulletCollision/CollisionDispatch/btSimulationIslandManager.cpp b/src/BulletCollision/CollisionDispatch/btSimulationIslandManager.cpp index 44e762823..bb2a7f239 100644 --- a/src/BulletCollision/CollisionDispatch/btSimulationIslandManager.cpp +++ b/src/BulletCollision/CollisionDispatch/btSimulationIslandManager.cpp @@ -392,15 +392,15 @@ void btSimulationIslandManager::buildAndProcessIslands(btDispatcher* dispatcher, int islandId = getUnionFind().getElement(startIslandIndex).m_id; - bool islandSleeping = false; + bool islandSleeping = true; for (endIslandIndex = startIslandIndex;(endIslandIndexisActive()) - islandSleeping = true; + if (colObj0->isActive()) + islandSleeping = false; } diff --git a/src/LinearMath/btMatrix3x3.h b/src/LinearMath/btMatrix3x3.h index 3c37f6e4f..bb4d97868 100644 --- a/src/LinearMath/btMatrix3x3.h +++ b/src/LinearMath/btMatrix3x3.h @@ -110,8 +110,8 @@ public: * Equivilant to this = this * m */ btMatrix3x3& operator*=(const btMatrix3x3& m); - /** @brief Set from a carray of btScalars - * @param m A pointer to the beginning of an array of 9 btScalars */ + /** @brief Set from the rotational part of a 4x4 OpenGL matrix + * @param m A pointer to the beginning of the array of scalars*/ void setFromOpenGLSubMatrix(const btScalar *m) { m_el[0].setValue(m[0],m[4],m[8]); @@ -208,7 +208,7 @@ public: return identityMatrix; } - /**@brief Fill the values of the matrix into a 9 element array + /**@brief Fill the rotational part of an OpenGL matrix and clear the shear/perspective * @param m The array to be filled */ void getOpenGLSubMatrix(btScalar *m) const {