Kinematics basic question

i m facing too many difficulties with physics simulation like kinematics,collision, bouncing etc.



is there a detailed theoretical documentation available which can help me in understanding what basically goes behind the scenes?



i have a basic question:

i have made a platform and set it to 0 mass.



new RigidBodyControl(0.0f);



so it doesn’t fall under gravity.



similarly i have a ball above platform, and if i set its mass to zero then it just hangs in air, otherwise it falls…all as expected.



now if i let ball fall by giving it mass then it collides with platform and rest upon it after some collision behabiour like bouncing etc…but ball falls only if i haven’t set kinematics to true.

if i do like this

((RigidBodyControl)ball.getControl(RigidBodyControl.class)).setKinematic(true);



then ball just hangs in mid air.



why such behaviour?



moreover,i have given user inputs which can tilt the platform so that ball rolls accordingly.

now if i set kinematics for platform to true:

((RigidBodyControl)platform.getControl(RigidBodyControl.class)).setKinematic(true);



only then ball rolls on platform…if i comment this code then ball has no rolling behaviour even if i tilt platform and it remains still.



can somone throw some light here?



in hellophysics tutorial, there is nothing like kinematics related code…and all collision, bouncing etc works fine.

Yes the physics tutorials do explain this.

You could also take a look at the Bullet Manual, although the classes and structs won’t match exactly. This document might also help.

1 Like

thanks survivor.



i read somewhere that meshing of colliding bodies also may cause unexpecte collision behaviour. is it true?

I don’t know. I’m a beginner, too. I try and modify until it works. :smiley:


now if i let ball fall by giving it mass then it collides with platform and rest upon it after some collision behabiour like bouncing etc…but ball falls only if i haven’t set kinematics to true.

This is called a dynamic object. Please take a look at the Bullet Manual, page 22, or in the jme3 wiki here at the section "Kinematic vs Dynamic vs Static".

if i do like this
((RigidBodyControl)ball.getControl(RigidBodyControl.class)).setKinematic(true);

then ball just hangs in mid air.

why such behaviour? [...]


I answered this here. Kinematic objects are animated by you (directly by calling i.e. physicsRigidBody.setPhysicsLocation(vector3f) or indirectly by the scene graph).
1 Like