[][src]Struct skeletal_animation::controller::AnimationController

pub struct AnimationController<T: Transform> { /* fields omitted */ }

A runtime representation of an Animation State Machine, consisting of one or more AnimationStates connected by AnimationTransitions, where the output animation pose depends on the current state or any active transitions between states.

Implementations

impl<T: Transform> AnimationController<T>[src]

pub fn new(
    controller_def: AnimationControllerDef,
    skeleton: Rc<Skeleton>,
    animations: &HashMap<ClipId, Rc<AnimationClip<T>>>
) -> AnimationController<T>
[src]

Create an AnimationController instance from its definition, the desired skeleton, and a collection of currently loaded animation clips.

pub fn update(&mut self, delta_time: f64)[src]

Update the controller's local clock with the given time delta

pub fn set_playback_speed(&mut self, speed: f64)[src]

Set the playback speed for the controller

pub fn set_param_value(&mut self, name: &str, value: f32)[src]

Set the value for the given controller parameter

pub fn get_param_value(&self, name: &str) -> f32[src]

Return the value for the given controller parameter

pub fn get_parameters(&self) -> &HashMap<String, f32>[src]

Return a read-only reference to the controller parameter map

pub fn get_output_pose<TOutput: Transform + FromTransform<T>>(
    &mut self,
    ext_dt: f64,
    output_poses: &mut [TOutput]
)
[src]

Calculate global skeletal joint poses for the given time since last update

Auto Trait Implementations

impl<T> !RefUnwindSafe for AnimationController<T>

impl<T> !Send for AnimationController<T>

impl<T> !Sync for AnimationController<T>

impl<T> Unpin for AnimationController<T>

impl<T> UnwindSafe for AnimationController<T> where
    T: RefUnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> SetParameter for T

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.