needsCollision of derived btCollisionDispatcher not called

User avatar
Tomator
Posts: 9
Joined: Mon Oct 18, 2010 8:53 am

needsCollision of derived btCollisionDispatcher not called

Post by Tomator »

Hi

I have a physical object that can contain other physical objects inside and then it shouldn't collide with (only) those objects. So I derived a btCollisionDispatcher's descendant to filter those collisions. It worked fine in the project... But doesn't do now. Here it looks like:

Code: Select all

	theBulletCollisionConfiguration = new btDefaultCollisionConfiguration();
	theBulletCollisionDispatcher = new DerivedCollisionDispatcher(theBulletCollisionConfiguration);
	btGImpactCollisionAlgorithm::registerAlgorithm(theBulletCollisionDispatcher);
	btVector3 worldMin(-1000, -1000, -1000);
	btVector3 worldMax(1000, 1000, 1000);
	theBulletBroadphase = new btAxisSweep3(worldMin, worldMax);
	theBulletConstraintSolver = new btSequentialImpulseConstraintSolver();
  theBulletWorld = new btDiscreteDynamicsWorld(theBulletCollisionDispatcher,
                                               theBulletBroadphase, 
                                               theBulletConstraintSolver,
                                               theBulletCollisionConfiguration);