Jump to content
  • Advertisement
Sign in to follow this  

How to make the bullet physics update faster?

Recommended Posts

My bullet physics simulation works very slowly. Let's say, one of the objects is lifting the other one, the takes many many many frames to update to the correct position. Just very laggy...

Can I increase the dt? or decrease it, to make the physics react better?


The fact is I use the gimpact shapes for the forks of the forklift, I can't decompose the forks into many boxes, it's too time consuming...

So I have one 4 bvh static mesh, 8 gimpacts, about 10 boxes...




Edited by lucky6969b

Share this post

Link to post
Share on other sites

This looks to me as if you are taking 100 sub-steps per tick which would indeed be very slow. Usually you pick a fixed time-step like 30, 60, 120, or even 240 Hz and a fixed number of sub-steps. For games 30 or 60 Hz is a typical choice. 

const int MaxSubSteps = 4
const float FixedTimeStep = 1.0f / 60.0f; // Or similar

pDynamicsWorld->stepSimulation( dt, MaxSubSteps ,FixedTimeStep );

I recommend checking out Glenn's post here:


And the Bullet Wiki:


You also posted a bunch of other questions regarding dynamic mesh shape (GImpact) collision. This is usually slow since this is just a very difficult problem. I would not use GImpact shapes in real-time simulations. Use simple hulls or compounds instead.

Edited by Dirk Gregorius

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!