[go: up one dir, main page]

Enum gltf::animation::Interpolation[][src]

pub enum Interpolation {
    Linear,
    Step,
    CatmullRomSpline,
    CubicSpline,
}

Specifies an interpolation algorithm.

Variants

Linear interpolation.

The animated values are linearly interpolated between keyframes. When targeting a rotation, spherical linear interpolation (slerp) should be used to interpolate quaternions. The number output of elements must equal the number of input elements.

Step interpolation.

The animated values remain constant to the output of the first keyframe, until the next keyframe. The number of output elements must equal the number of input elements.

Uniform Catmull-Rom spline interpolation.

The animation's interpolation is computed using a uniform Catmull-Rom spline. The number of output elements must equal two more than the number of input elements. The first and last output elements represent the start and end tangents of the spline. There must be at least four keyframes when using this interpolation.

Cubic spline interpolation.

The animation's interpolation is computed using a uniform Catmull-Rom spline. The number of output elements must equal two more than the number of input elements. The first and last output elements represent the start and end tangents of the spline. There must be at least four keyframes when using this interpolation.

Trait Implementations

impl Serialize for Interpolation
[src]

Serialize this value into the given Serde serializer. Read more

impl Clone for Interpolation
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Default for Interpolation
[src]

Returns the "default value" for a type. Read more

impl Debug for Interpolation
[src]

Formats the value using the given formatter. Read more

impl Copy for Interpolation
[src]

impl<'de> Deserialize<'de> for Interpolation
[src]

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations