There is no interpolation with physics.
I tried to repro the jitter in FF but I didn’t see anything particular.
Can you record this jitter?
In the PG, the size of the world and forces are set to show the PhysicsHelper. In the demo, they are set for fast action in a small world. So, in the PG, it may look like action is happening on the moon, not in the demo.
I’m sorry for answering late, but this keeps popping up.
Physics runs at it’s own speed, frames runs at their own speed. Frames are not steady, physics tick is.
That’s why you need interpolation: if you just show what the physics engine spit out on every frame, you get jerky motion.
What good is 100’s of FPS, if for example 3 frames shows the same position, then the next frame there’s movement? This is why one needs interpolation, and that’s how it is done in all modern game engines. (before the extra step of motion blur)
If you have a setup of 2 monitors to ensure your computer has something to do, then run this:
you will notice that the ball is not dropping silky smooth, despite possibly hundreds of FPS.
Yes, I can, and have recorded it, but the argument would just be “that’s because of the video capture” as it will often get extremely jerky on capture due to even more FPS variants injected…
It’s really not a matter of showing but knowing that Physics need to be inter- or extrapolated (or extremely over sampled which is a poor solution) to be represented smoothly. And Babylon.js w Havok has no way of doing this?
Correct me if I’m wrong @Evgeni_Popov and @sebavan but I think physics update is done for every rendered frame. So, if the physics update is using fixed delta time then physics will appear to run faster on fast refresh screens. If it’s using delta time update, then there is no limit in physics update.
I’m still new to Babylon, am more an artist than programmer, and I still cannot get the smooth physics animations / across varying FPS that I can get in other engines using out of the box “Interpolate” functions on rigidbodies.
Are you guys saying that I’m wrong or that’s how it is, or trying to tell me something I don’t get on how to achieve smooth physics in Babylon?