Struct nphysics2d::integration::BodyDamping [] [src]

pub struct BodyDamping<N: Real> { /* fields omitted */ }

A linear and angular velocity damper.

This will remove a part of the linear and angular velocity of every rigid body at each frame. Do not use unless you are experiencing unrealistic vibrations or very unstable joints.

Methods

impl<N: Real> BodyDamping<N>
[src]

[src]

Creates a new BodyDamping.

Arguments:

  • linear_damping - coefficient in [0, 1] the linear velocity of each rigid body is multiplied at each update.
  • linear_damping - coefficient in [0, 1] the angular velocity of each rigid body is multiplied at each update.

Trait Implementations

impl<N: Real> Integrator<N, RigidBody<N>> for BodyDamping<N>
[src]

[src]

Updates the position and orientation of the object o after a time step of dt.