Struct blit::aseprite_feature::Animation
[−]
[src]
pub struct Animation { /* fields omitted */ }
The actual animation which contains the status about which frame should be played.
Methods
impl Animation
[src]
pub fn start(frame_start: usize, frame_end: usize, repeat: bool) -> Self
[src]
Start an animation with a frame range, the duration of each frame is described in the aseprite metadata.
pub fn start_from_tag(
buffer: &AnimationBlitBuffer,
tag: String,
repeat: bool
) -> Result<Self, AnimationError>
[src]
buffer: &AnimationBlitBuffer,
tag: String,
repeat: bool
) -> Result<Self, AnimationError>
Start an animation with a range as described matching with a tag in the aseprite metadata.
pub fn update(
&mut self,
buffer: &AnimationBlitBuffer,
dt: Duration
) -> Result<AnimationStatus, Box<Error>>
[src]
&mut self,
buffer: &AnimationBlitBuffer,
dt: Duration
) -> Result<AnimationStatus, Box<Error>>
Update the animation with the time and set the current frame to the correct one.
Trait Implementations
impl Debug for Animation
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more