physics
Settings for the physics engine.
Attributes
Attribute | Type | Default | Description |
---|---|---|---|
gravity | vec3 | [ 0, -9.8, 0 ] | Global gravity applied throughout the scene. |
toleranceLength | float | 1 | The approximate size of objects in the simulation. This is used to estimate certain length-related tolerances. |
toleranceSpeed | float | 10 | The typical magnitude of velocities of objects in simulation. This is used to estimate whether a contact should be treated as bouncing or resting based on its impact velocity, and a kinetic energy threshold below which the simulation may put objects to sleep. For normal physical environments, a good choice is the approximate speed of an object falling under gravity for one second. |