pub trait AnimationState: Clone {
    // Provided method
    fn interpolate(old: &Self, new: &Self, t: f64) -> Self { ... }
}
Expand description

Trait required from states given to Animations.

Provided Methods§

source

fn interpolate(old: &Self, new: &Self, t: f64) -> Self

Interpolate between two states.

Used to create smooth animations even if the simulation timestep is long. The default implementation does not do any interpolation.

Object Safety§

This trait is not object safe.

Implementors§