pub struct Playback {
pub clip: usize,
pub elapsed: i64,
pub sample_time: i64,
pub sample_delta: i64,
pub speed: f32,
}Expand description
Single, unique animation playback. Tree expiry starts from an empty animation state. Blended stacks and AnimationManager’s shared instances require their separate lifecycle port.
Fields§
§clip: usizeThe clip.
elapsed: i64The time played so far.
sample_time: i64UpdateNodes publishes the pose at the OLD clock, then Update advances elapsed.
sample_delta: i64The time step of the last sample.
speed: f32The playback speed.
Implementations§
Source§impl Playback
impl Playback
Sourcepub fn new(clip: usize, start: i64) -> Self
pub fn new(clip: usize, start: i64) -> Self
A clip that starts playing at start, at speed 1. Tree removal starts at time zero.
Original: FUN_14012a5c0; AnimationState::PlayAnimation, Runtime 0x1801007e0.
Sourcepub fn is_animating(&self, clip: &AnimationClip) -> bool
pub fn is_animating(&self, clip: &AnimationClip) -> bool
Whether the clip is still playing. The end comes from the clip’s stored duration (with its rounded value), not from frames and rate.
Original: MeshInstance::IsAnimating, Runtime 0x180102060.
Trait Implementations§
impl StructuralPartialEq for Playback
Auto Trait Implementations§
impl Freeze for Playback
impl RefUnwindSafe for Playback
impl Send for Playback
impl Sync for Playback
impl Unpin for Playback
impl UnsafeUnpin for Playback
impl UnwindSafe for Playback
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more