btKinematicCharacterController wierd when size gets larger

Post Reply
spixxel
Posts: 8
Joined: Sun Feb 05, 2012 12:25 am

btKinematicCharacterController wierd when size gets larger

Post by spixxel »

Hi, i have made some test program that uses btKinematicCharacterControllers to simulate humanoids that can walk around but I have some problems that I don't know why the occur.

When I increase the size of the charactercontroller, or more preciesly the size of the capsuleshape that the ghost object contains and performance goes down rapidally

When the capsule is 0.75*0.75 then the stepphysics takes approx 0.55 ms

and dispatchAllCollisionPairs takes 0.05 ms
and updateActions takes 0.435 ms

but when I let the capsule size be 30*30 then the difference is huge.

then in 1 frame the stepsimulation takes 103 ms

and updateActions takes 97.097 ms
and dispatchAllCollisionPairs takes 5.915 ms

is this normal?, nothing else is changed and the charactercontrollers are not colliding with eachother

very glad for as many responses as possible (as long as they have suqqestions and information)

/Per
spixxel
Posts: 8
Joined: Sun Feb 05, 2012 12:25 am

Re: btKinematicCharacterController wierd when size gets larg

Post by spixxel »

any1 got an idea about why?, would appreciate every suggestion
Pentium166
Posts: 4
Joined: Thu Feb 07, 2013 4:26 pm

Re: btKinematicCharacterController wierd when size gets larg

Post by Pentium166 »

I'm having the same problem, I've searched the forum for it but this one is the closest with the problem I'm having now.
Does anyone have any ideia???
MaxDZ8
Posts: 149
Joined: Fri Jun 24, 2011 8:53 am

Re: btKinematicCharacterController wierd when size gets larg

Post by MaxDZ8 »

I speculate much more manifolds are generated. Mind checking your manifold count?
Pentium166
Posts: 4
Joined: Thu Feb 07, 2013 4:26 pm

Re: btKinematicCharacterController wierd when size gets larg

Post by Pentium166 »

MaxDZ8 wrote:I speculate much more manifolds are generated. Mind checking your manifold count?
Sorry I forgot to tell that english isn't my first language and also...I'm a newbie on bullet (started two weeks ago) so...how do I do that???
MaxDZ8
Posts: 149
Joined: Fri Jun 24, 2011 8:53 am

Re: btKinematicCharacterController wierd when size gets larg

Post by MaxDZ8 »

Call btCollisionDispatcher::getNumManifolds().
Pentium166
Posts: 4
Joined: Thu Feb 07, 2013 4:26 pm

Re: btKinematicCharacterController wierd when size gets larg

Post by Pentium166 »

It's 2...it's always 2...even in the parts where I got slowdowns...
MaxDZ8
Posts: 149
Joined: Fri Jun 24, 2011 8:53 am

Re: btKinematicCharacterController wierd when size gets larg

Post by MaxDZ8 »

What broadphase are you using? I might want to investigate that.
Pentium166
Posts: 4
Joined: Thu Feb 07, 2013 4:26 pm

Re: btKinematicCharacterController wierd when size gets larg

Post by Pentium166 »

Code: Select all

broadphase             = new btAxisSweep3(VECTOR3D(-200,-200,-200), VECTOR3D(200,200,200), MAX_PROXIES);
collisionConfiguration = new btDefaultCollisionConfiguration();
dispatcher               = new btCollisionDispatcher(collisionConfiguration);
solver                     = new btSequentialImpulseConstraintSolver();
dynamicsWorld         = new btDiscreteDynamicsWorld(dispatcher, broadphase, solver, collisionConfiguration);
MaxDZ8
Posts: 149
Joined: Fri Jun 24, 2011 8:53 am

Re: btKinematicCharacterController wierd when size gets larg

Post by MaxDZ8 »

I'm sorry I've grossly failed to explain myself.
I would like to replicate your experiment so I can investigate.
Do you mind sharing the code?

In the meanwhile, also try btDvbtBroadphase.
Post Reply