Skip to main content

Animate

Trait Animate 

Source
pub trait Animate {
    type Value;

    // Required methods
    fn update(&mut self);
    fn get(&self) -> &Self::Value;
    fn set(&mut self, target: Self::Value);
    fn target(&self) -> &Self::Value;
}

Required Associated Types§

Required Methods§

Source

fn update(&mut self)

Source

fn get(&self) -> &Self::Value

Source

fn set(&mut self, target: Self::Value)

Source

fn target(&self) -> &Self::Value

Implementors§

Source§

impl<T, E, I> Animate for Tween<T, E, I, Alternate>
where T: TweenAnim + PartialEq + Default, E: Fn(f64) -> f64, I: Fn(&T, &T, f64) -> T,

Source§

type Value = T

Source§

impl<T, E, I> Animate for Tween<T, E, I, Cycle>
where T: TweenAnim + PartialEq + Default, E: Fn(f64) -> f64, I: Fn(&T, &T, f64) -> T,

Source§

type Value = T

Source§

impl<T, E, I> Animate for Tween<T, E, I, Once>
where T: TweenAnim + PartialEq + Default, E: Fn(f64) -> f64, I: Fn(&T, &T, f64) -> T,

Source§

type Value = T

Source§

impl<T, I> Animate for Spring<T, I, Alternate>
where T: SpringAnim + PartialEq + Distance, T::Velocity: Settled, I: Fn(&T, &T, &T::Velocity, SpringParams, f64) -> (T, T::Velocity),

Source§

type Value = T

Source§

impl<T, I> Animate for Spring<T, I, Cycle>
where T: SpringAnim + PartialEq + Distance, T::Velocity: Settled, I: Fn(&T, &T, &T::Velocity, SpringParams, f64) -> (T, T::Velocity),

Source§

type Value = T

Source§

impl<T, I> Animate for Spring<T, I, Once>
where T: SpringAnim + PartialEq + Distance, T::Velocity: Settled, I: Fn(&T, &T, &T::Velocity, SpringParams, f64) -> (T, T::Velocity),

Source§

type Value = T