diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2020-12-30 14:07:15 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-30 14:07:15 +0100 |
commit | f1cb475d9b1389bed00f252603ea7b05880c83ab (patch) | |
tree | ae9e63c4c5fa49e56da998483f41e6faccea926d | |
parent | f69c116fa7b93b7a6e2aac7456fa547023335d7c (diff) | |
parent | e495c2cb21f57e89e62a8d950411cdfa37dd8852 (diff) |
Merge pull request #44807 from akien-mga/bullet-3.08
bullet: Sync with upstream 3.08
-rw-r--r-- | thirdparty/README.md | 2 | ||||
-rw-r--r-- | thirdparty/bullet/BulletDynamics/Featherstone/btMultiBody.cpp | 5 | ||||
-rw-r--r-- | thirdparty/bullet/BulletDynamics/Featherstone/btMultiBody.h | 3 | ||||
-rw-r--r-- | thirdparty/bullet/LinearMath/btQuickprof.cpp | 3 | ||||
-rw-r--r-- | thirdparty/bullet/LinearMath/btScalar.h | 2 | ||||
-rw-r--r-- | thirdparty/bullet/LinearMath/btSerializer.h | 2 |
6 files changed, 12 insertions, 5 deletions
diff --git a/thirdparty/README.md b/thirdparty/README.md index 8075ec43ab..68bb11d14f 100644 --- a/thirdparty/README.md +++ b/thirdparty/README.md @@ -22,7 +22,7 @@ Files extracted from upstream source: ## bullet - Upstream: https://github.com/bulletphysics/bullet3 -- Version: 3.07 (e32fc59c88a3908876949c6f2665e8d091d987fa, 2020) +- Version: 3.08 (df09fd9ed37e365ceae884ca7f620b61607dae2e, 2020) - License: zlib Files extracted from upstream source: diff --git a/thirdparty/bullet/BulletDynamics/Featherstone/btMultiBody.cpp b/thirdparty/bullet/BulletDynamics/Featherstone/btMultiBody.cpp index bec8c6530d..7cb92fa3b4 100644 --- a/thirdparty/bullet/BulletDynamics/Featherstone/btMultiBody.cpp +++ b/thirdparty/bullet/BulletDynamics/Featherstone/btMultiBody.cpp @@ -125,7 +125,8 @@ btMultiBody::btMultiBody(int n_links, m_posVarCnt(0), m_useRK4(false), m_useGlobalVelocities(false), - m_internalNeedsJointFeedback(false) + m_internalNeedsJointFeedback(false), + m_kinematic_calculate_velocity(false) { m_cachedInertiaTopLeft.setValue(0, 0, 0, 0, 0, 0, 0, 0, 0); m_cachedInertiaTopRight.setValue(0, 0, 0, 0, 0, 0, 0, 0, 0); @@ -2381,7 +2382,7 @@ const char *btMultiBody::serialize(void *dataBuffer, class btSerializer *seriali void btMultiBody::saveKinematicState(btScalar timeStep) { //todo: clamp to some (user definable) safe minimum timestep, to limit maximum angular/linear velocities - if (timeStep != btScalar(0.)) + if (m_kinematic_calculate_velocity && timeStep != btScalar(0.)) { btVector3 linearVelocity, angularVelocity; btTransformUtil::calculateVelocity(getInterpolateBaseWorldTransform(), getBaseWorldTransform(), timeStep, linearVelocity, angularVelocity); diff --git a/thirdparty/bullet/BulletDynamics/Featherstone/btMultiBody.h b/thirdparty/bullet/BulletDynamics/Featherstone/btMultiBody.h index 25112a6805..5a3efc9414 100644 --- a/thirdparty/bullet/BulletDynamics/Featherstone/btMultiBody.h +++ b/thirdparty/bullet/BulletDynamics/Featherstone/btMultiBody.h @@ -823,6 +823,9 @@ private: ///the m_needsJointFeedback gets updated/computed during the stepVelocitiesMultiDof and it for internal usage only bool m_internalNeedsJointFeedback; + + //If enabled, calculate the velocity based on kinematic transform changes. Currently only implemented for the base. + bool m_kinematic_calculate_velocity; }; struct btMultiBodyLinkDoubleData diff --git a/thirdparty/bullet/LinearMath/btQuickprof.cpp b/thirdparty/bullet/LinearMath/btQuickprof.cpp index 86fd1d7812..33b51eb763 100644 --- a/thirdparty/bullet/LinearMath/btQuickprof.cpp +++ b/thirdparty/bullet/LinearMath/btQuickprof.cpp @@ -720,6 +720,9 @@ void btLeaveProfileZoneDefault() #define BT_HAVE_TLS 1 #elif __linux__ #define BT_HAVE_TLS 1 +#elif defined(__FreeBSD__) || defined(__NetBSD__) + // TODO: At the moment disabling purposely OpenBSD, albeit tls support exists but not fully functioning + #define BT_HAVE_TLS 1 #endif // __thread is broken on Andorid clang until r12b. See diff --git a/thirdparty/bullet/LinearMath/btScalar.h b/thirdparty/bullet/LinearMath/btScalar.h index 36b90cc944..0402146af1 100644 --- a/thirdparty/bullet/LinearMath/btScalar.h +++ b/thirdparty/bullet/LinearMath/btScalar.h @@ -25,7 +25,7 @@ subject to the following restrictions: #include <float.h> /* SVN $Revision$ on $Date$ from http://bullet.googlecode.com*/ -#define BT_BULLET_VERSION 307 +#define BT_BULLET_VERSION 308 inline int btGetVersion() { diff --git a/thirdparty/bullet/LinearMath/btSerializer.h b/thirdparty/bullet/LinearMath/btSerializer.h index 9abcf031d0..4d1c760e24 100644 --- a/thirdparty/bullet/LinearMath/btSerializer.h +++ b/thirdparty/bullet/LinearMath/btSerializer.h @@ -481,7 +481,7 @@ public: buffer[9] = '3'; buffer[10] = '0'; - buffer[11] = '7'; + buffer[11] = '8'; } virtual void startSerialization() |