Page 1 of 1

inner simulation steps and callback

Posted: Wed Nov 28, 2007 10:36 am
by topcomer
I managed to write a collision callback which gives me all the contact info I need, however I get a seamless stream of contacts coming from the inner simulation steps and I'm hence not able to understand when one of this substeps finishes and the other starts. Is there a way to know that without having to implement a new constraint solver by myself?

Thanks for the help,
Alessio

Re: inner simulation steps and callback

Posted: Wed Nov 28, 2007 6:59 pm
by Erwin Coumans
Can you derive your class from btDiscreteDynamicsWorld, and override the

Code: Select all

virtual void	internalSingleStepSimulation( btScalar timeStep);
and call the original implementation first, and then do your contact callback/processing.

A contact callback demo will be added for Bullet 2.65.

Hope this helps,
Erwin