From eee51f39f97dad2dc09533a636e5a8cbceb6a67e Mon Sep 17 00:00:00 2001 From: Riccardo Balbo Date: Fri, 29 Apr 2016 14:31:08 +0200 Subject: [PATCH] Add GImpact collision algorithm to physics spaces --- jme3-bullet-native/src/native/cpp/jmePhysicsSpace.cpp | 2 ++ jme3-bullet-native/src/native/cpp/jmePhysicsSpace.h | 1 + 2 files changed, 3 insertions(+) diff --git a/jme3-bullet-native/src/native/cpp/jmePhysicsSpace.cpp b/jme3-bullet-native/src/native/cpp/jmePhysicsSpace.cpp index 8cb80bc87..6a9e248de 100644 --- a/jme3-bullet-native/src/native/cpp/jmePhysicsSpace.cpp +++ b/jme3-bullet-native/src/native/cpp/jmePhysicsSpace.cpp @@ -147,6 +147,8 @@ void jmePhysicsSpace::createPhysicsSpace(jfloat minX, jfloat minY, jfloat minZ, } else { dispatcher = new btCollisionDispatcher(collisionConfiguration); } + btGImpactCollisionAlgorithm::registerAlgorithm(dispatcher); + // the default constraint solver. For parallel processing you can use a different solver (see Extras/BulletMultiThreaded) if (threading) { diff --git a/jme3-bullet-native/src/native/cpp/jmePhysicsSpace.h b/jme3-bullet-native/src/native/cpp/jmePhysicsSpace.h index 2e2b3865c..f3e3e2503 100644 --- a/jme3-bullet-native/src/native/cpp/jmePhysicsSpace.h +++ b/jme3-bullet-native/src/native/cpp/jmePhysicsSpace.h @@ -48,6 +48,7 @@ #include "BulletCollision/CollisionDispatch/btSimulationIslandManager.h" #include "BulletCollision/NarrowPhaseCollision/btManifoldPoint.h" #include "BulletCollision/NarrowPhaseCollision/btPersistentManifold.h" +#include "BulletCollision/Gimpact/btGImpactCollisionAlgorithm.h" /** * Author: Normen Hansen