Page 1 of 1

Thread Safety in the Bullet API

Posted: Fri Jun 26, 2015 5:02 pm
by Xenoprimate
Hi guys - I couldn't find information on this anywhere: How thread-safe is the bullet API? As an example, could I create a btCollisionShape on one thread, update its local scaling on a second, and then add it to a btDyamicsWorld on a third, before say, removing it from a fourth? (Free threading)

Or do I need to be more careful? (Single-threaded only or explicit synchronization)

I'm only talking about thread safety with respect to calling the API, not synchronization that must be done on my own side (e.g. updating shared lists of rigid bodies etc).

Re: Thread Safety in the Bullet API

Posted: Fri Aug 07, 2015 9:15 am
by Xenoprimate
Sorry to bump, but I'd really like some further insight on this one! - At the moment I'm coercing all calls through a single "master" thread just to be safe.

Re: Thread Safety in the Bullet API

Posted: Tue Aug 11, 2015 11:33 am
by Basroil
Some files are not thread safe (especially the MLCP solvers), but most things will be safe as long as you do it before stepping. If you want heavy thread safety and multithread support, there's a great fork on github that makes everything far easier (and sometimes faster)

Re: Thread Safety in the Bullet API

Posted: Tue Aug 11, 2015 7:42 pm
by drleviathan
And there is a thread on these forums that talks about that multi-thread fork.