From bc34d0129ec94c6240ba970e8d7247998afc4e32 Mon Sep 17 00:00:00 2001 From: Kotik Andreev Date: Mon, 31 Oct 2016 01:45:44 +0300 Subject: [PATCH 1/5] Fix a little typo --- src/BulletCollision/CollisionShapes/btCollisionShape.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/BulletCollision/CollisionShapes/btCollisionShape.h b/src/BulletCollision/CollisionShapes/btCollisionShape.h index 5e8656800..6c4916fbd 100644 --- a/src/BulletCollision/CollisionShapes/btCollisionShape.h +++ b/src/BulletCollision/CollisionShapes/btCollisionShape.h @@ -48,7 +48,7 @@ public: virtual void getBoundingSphere(btVector3& center,btScalar& radius) const; - ///getAngularMotionDisc returns the maximus radius needed for Conservative Advancement to handle time-of-impact with rotations. + ///getAngularMotionDisc returns the maximum radius needed for Conservative Advancement to handle time-of-impact with rotations. virtual btScalar getAngularMotionDisc() const; virtual btScalar getContactBreakingThreshold(btScalar defaultContactThresholdFactor) const; From ec78184604352afedd2e48c0ae7fa4fb0dd36533 Mon Sep 17 00:00:00 2001 From: erwincoumans Date: Mon, 7 Nov 2016 08:42:39 -0800 Subject: [PATCH 2/5] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 19d90086b..5c654bd04 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ # Bullet Physics SDK -This is the official C++ source code repository of the Bullet Physics SDK: real-time collision detection and multi-physics simulation for games, visual effects, robotics etc. +This is the official C++ source code repository of the Bullet Physics SDK: real-time collision detection and multi-physics simulation for VR, games, visual effects, robotics, machine learning etc. New in Bullet 2.85: pybullet Python bindings, improved support for robotics and VR From 02c781e56b6ebea980e2a52be91bcd8170954ff3 Mon Sep 17 00:00:00 2001 From: erwincoumans Date: Thu, 10 Nov 2016 15:42:55 -0800 Subject: [PATCH 3/5] disable dead code --- examples/MultiThreadedDemo/MultiThreadedDemo.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/examples/MultiThreadedDemo/MultiThreadedDemo.cpp b/examples/MultiThreadedDemo/MultiThreadedDemo.cpp index d07ef4ca2..d3a54856b 100644 --- a/examples/MultiThreadedDemo/MultiThreadedDemo.cpp +++ b/examples/MultiThreadedDemo/MultiThreadedDemo.cpp @@ -199,7 +199,7 @@ void MultiThreadedDemo::createSceneObjects() } } } - +#if 0 if ( false ) { // destroyer ball @@ -211,6 +211,7 @@ void MultiThreadedDemo::createSceneObjects() btRigidBody* ballBody = localCreateRigidBody( 10000.f, sphereTrans, ball ); ballBody->setLinearVelocity( btVector3( 0, 0, -10 ) ); } +#endif m_guiHelper->autogenerateGraphicsObjects( m_dynamicsWorld ); } From fd90589cc2337d503c1c1e688fb04afbffd75f1f Mon Sep 17 00:00:00 2001 From: erwincoumans Date: Thu, 10 Nov 2016 15:44:03 -0800 Subject: [PATCH 4/5] disable dead code --- examples/SharedMemory/PhysicsServerCommandProcessor.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/examples/SharedMemory/PhysicsServerCommandProcessor.cpp b/examples/SharedMemory/PhysicsServerCommandProcessor.cpp index 28ed1a81d..68f30944a 100644 --- a/examples/SharedMemory/PhysicsServerCommandProcessor.cpp +++ b/examples/SharedMemory/PhysicsServerCommandProcessor.cpp @@ -4083,6 +4083,7 @@ void PhysicsServerCommandProcessor::createDefaultRobotAssets() } //directly set the position of the links, only for debugging IK, don't use this method! +#if 0 if (0) { for (int i=0;igetNumLinks();i++) @@ -4091,6 +4092,7 @@ void PhysicsServerCommandProcessor::createDefaultRobotAssets() mb->setJointPosMultiDof(i,&desiredPosition); } } else +#endif { int numMotors = 0; //find the joint motors and apply the desired velocity and maximum force/torque From 3b5d0f444bb96b25dd9b6746ac0b28417831f7dd Mon Sep 17 00:00:00 2001 From: Erwin Coumans Date: Thu, 10 Nov 2016 16:18:20 -0800 Subject: [PATCH 5/5] various fixes move btSimulationIslandManagerMt.cpp from BulletCollision to BulletDynamics --- examples/MultiThreadedDemo/CommonRigidBodyMTBase.cpp | 2 +- examples/SharedMemory/PhysicsServerCommandProcessor.cpp | 4 ++-- examples/pybullet/pybullet.c | 6 +++--- src/BulletCollision/CMakeLists.txt | 2 -- src/BulletDynamics/CMakeLists.txt | 2 ++ src/BulletDynamics/Dynamics/btDiscreteDynamicsWorldMt.cpp | 2 +- .../Dynamics}/btSimulationIslandManagerMt.cpp | 0 .../Dynamics}/btSimulationIslandManagerMt.h | 2 +- 8 files changed, 10 insertions(+), 10 deletions(-) rename src/{BulletCollision/CollisionDispatch => BulletDynamics/Dynamics}/btSimulationIslandManagerMt.cpp (100%) rename src/{BulletCollision/CollisionDispatch => BulletDynamics/Dynamics}/btSimulationIslandManagerMt.h (98%) diff --git a/examples/MultiThreadedDemo/CommonRigidBodyMTBase.cpp b/examples/MultiThreadedDemo/CommonRigidBodyMTBase.cpp index 6edada4de..26e430cc2 100644 --- a/examples/MultiThreadedDemo/CommonRigidBodyMTBase.cpp +++ b/examples/MultiThreadedDemo/CommonRigidBodyMTBase.cpp @@ -27,7 +27,7 @@ class btCollisionShape; #include "LinearMath/btAlignedObjectArray.h" #include "LinearMath/btPoolAllocator.h" #include "btBulletCollisionCommon.h" -#include "BulletCollision/CollisionDispatch/btSimulationIslandManagerMt.h" // for setSplitIslands() +#include "BulletDynamics/Dynamics/btSimulationIslandManagerMt.h" // for setSplitIslands() #include "BulletDynamics/Dynamics/btDiscreteDynamicsWorldMt.h" #include "BulletDynamics/ConstraintSolver/btSequentialImpulseConstraintSolver.h" diff --git a/examples/SharedMemory/PhysicsServerCommandProcessor.cpp b/examples/SharedMemory/PhysicsServerCommandProcessor.cpp index 68f30944a..6f81102ef 100644 --- a/examples/SharedMemory/PhysicsServerCommandProcessor.cpp +++ b/examples/SharedMemory/PhysicsServerCommandProcessor.cpp @@ -4083,7 +4083,7 @@ void PhysicsServerCommandProcessor::createDefaultRobotAssets() } //directly set the position of the links, only for debugging IK, don't use this method! -#if 0 +#if 0 if (0) { for (int i=0;igetNumLinks();i++) @@ -4092,7 +4092,7 @@ void PhysicsServerCommandProcessor::createDefaultRobotAssets() mb->setJointPosMultiDof(i,&desiredPosition); } } else -#endif +#endif { int numMotors = 0; //find the joint motors and apply the desired velocity and maximum force/torque diff --git a/examples/pybullet/pybullet.c b/examples/pybullet/pybullet.c index a38d427fd..531c49994 100644 --- a/examples/pybullet/pybullet.c +++ b/examples/pybullet/pybullet.c @@ -2580,17 +2580,17 @@ static PyMethodDef SpamMethods[] = { #endif }, - {"getContactPoints", pybullet_getContactPointData, METH_VARARGS | METH_KEYWORDS, + {"getContactPoints", (PyCFunction)pybullet_getContactPointData, METH_VARARGS | METH_KEYWORDS, "Return existing contact points after the stepSimulation command. " "Optional arguments one or two object unique " "ids, that need to be involved in the contact."}, - {"getClosestPoints", pybullet_getClosestPointData, METH_VARARGS | METH_KEYWORDS, + {"getClosestPoints", (PyCFunction)pybullet_getClosestPointData, METH_VARARGS | METH_KEYWORDS, "Compute the closest points between two objects, if the distance is below a given threshold." "Input is two objects unique ids and distance threshold." }, - { "getOverlappingObjects", pybullet_getOverlappingObjects, METH_VARARGS | METH_KEYWORDS, + { "getOverlappingObjects", (PyCFunction)pybullet_getOverlappingObjects, METH_VARARGS | METH_KEYWORDS, "Return all the objects that have overlap with a given " "axis-aligned bounding box volume (AABB)." "Input are two vectors defining the AABB in world space [min_x,min_y,min_z],[max_x,max_y,max_z]." diff --git a/src/BulletCollision/CMakeLists.txt b/src/BulletCollision/CMakeLists.txt index 1e54a9494..90741a126 100644 --- a/src/BulletCollision/CMakeLists.txt +++ b/src/BulletCollision/CMakeLists.txt @@ -33,7 +33,6 @@ SET(BulletCollision_SRCS CollisionDispatch/btInternalEdgeUtility.h CollisionDispatch/btManifoldResult.cpp CollisionDispatch/btSimulationIslandManager.cpp - CollisionDispatch/btSimulationIslandManagerMt.cpp CollisionDispatch/btSphereBoxCollisionAlgorithm.cpp CollisionDispatch/btSphereSphereCollisionAlgorithm.cpp CollisionDispatch/btSphereTriangleCollisionAlgorithm.cpp @@ -141,7 +140,6 @@ SET(CollisionDispatch_HDRS CollisionDispatch/btHashedSimplePairCache.h CollisionDispatch/btManifoldResult.h CollisionDispatch/btSimulationIslandManager.h - CollisionDispatch/btSimulationIslandManagerMt.h CollisionDispatch/btSphereBoxCollisionAlgorithm.h CollisionDispatch/btSphereSphereCollisionAlgorithm.h CollisionDispatch/btSphereTriangleCollisionAlgorithm.h diff --git a/src/BulletDynamics/CMakeLists.txt b/src/BulletDynamics/CMakeLists.txt index f3d33fc90..4023d721e 100644 --- a/src/BulletDynamics/CMakeLists.txt +++ b/src/BulletDynamics/CMakeLists.txt @@ -22,6 +22,7 @@ SET(BulletDynamics_SRCS ConstraintSolver/btUniversalConstraint.cpp Dynamics/btDiscreteDynamicsWorld.cpp Dynamics/btDiscreteDynamicsWorldMt.cpp + Dynamics/btSimulationIslandManagerMt.cpp Dynamics/btRigidBody.cpp Dynamics/btSimpleDynamicsWorld.cpp # Dynamics/Bullet-C-API.cpp @@ -72,6 +73,7 @@ SET(Dynamics_HDRS Dynamics/btActionInterface.h Dynamics/btDiscreteDynamicsWorld.h Dynamics/btDiscreteDynamicsWorldMt.h + Dynamics/btSimulationIslandManagerMt.h Dynamics/btDynamicsWorld.h Dynamics/btSimpleDynamicsWorld.h Dynamics/btRigidBody.h diff --git a/src/BulletDynamics/Dynamics/btDiscreteDynamicsWorldMt.cpp b/src/BulletDynamics/Dynamics/btDiscreteDynamicsWorldMt.cpp index d0906e9c5..5f4aaa4db 100644 --- a/src/BulletDynamics/Dynamics/btDiscreteDynamicsWorldMt.cpp +++ b/src/BulletDynamics/Dynamics/btDiscreteDynamicsWorldMt.cpp @@ -21,7 +21,7 @@ subject to the following restrictions: #include "BulletCollision/BroadphaseCollision/btSimpleBroadphase.h" #include "BulletCollision/BroadphaseCollision/btCollisionAlgorithm.h" #include "BulletCollision/CollisionShapes/btCollisionShape.h" -#include "BulletCollision/CollisionDispatch/btSimulationIslandManagerMt.h" +#include "btSimulationIslandManagerMt.h" #include "LinearMath/btTransformUtil.h" #include "LinearMath/btQuickprof.h" diff --git a/src/BulletCollision/CollisionDispatch/btSimulationIslandManagerMt.cpp b/src/BulletDynamics/Dynamics/btSimulationIslandManagerMt.cpp similarity index 100% rename from src/BulletCollision/CollisionDispatch/btSimulationIslandManagerMt.cpp rename to src/BulletDynamics/Dynamics/btSimulationIslandManagerMt.cpp diff --git a/src/BulletCollision/CollisionDispatch/btSimulationIslandManagerMt.h b/src/BulletDynamics/Dynamics/btSimulationIslandManagerMt.h similarity index 98% rename from src/BulletCollision/CollisionDispatch/btSimulationIslandManagerMt.h rename to src/BulletDynamics/Dynamics/btSimulationIslandManagerMt.h index c1f5018bd..117061623 100644 --- a/src/BulletCollision/CollisionDispatch/btSimulationIslandManagerMt.h +++ b/src/BulletDynamics/Dynamics/btSimulationIslandManagerMt.h @@ -16,7 +16,7 @@ subject to the following restrictions: #ifndef BT_SIMULATION_ISLAND_MANAGER_MT_H #define BT_SIMULATION_ISLAND_MANAGER_MT_H -#include "btSimulationIslandManager.h" +#include "BulletCollision/CollisionDispatch/btSimulationIslandManager.h" class btTypedConstraint;