pub struct MotionTimelineSample { /* private fields */ }Expand description
A sampled point on a motion timeline.
Implementations§
Source§impl MotionTimelineSample
impl MotionTimelineSample
Sourcepub const fn new(
state: MotionRunState,
elapsed: Duration,
raw_progress: f32,
progress: f32,
) -> Self
pub const fn new( state: MotionRunState, elapsed: Duration, raw_progress: f32, progress: f32, ) -> Self
Creates a sample from explicit values.
Sourcepub const fn state(self) -> MotionRunState
pub const fn state(self) -> MotionRunState
Returns the sampled timeline state.
Sourcepub const fn raw_progress(self) -> f32
pub const fn raw_progress(self) -> f32
Returns the unclamped easing input after duration normalization.
Sourcepub const fn is_active(self) -> bool
pub const fn is_active(self) -> bool
Returns whether the timeline should continue requesting frames.
Sourcepub const fn reached_final_state(self) -> bool
pub const fn reached_final_state(self) -> bool
Returns whether the semantic final state has been reached.
Trait Implementations§
Source§impl Clone for MotionTimelineSample
impl Clone for MotionTimelineSample
impl Copy for MotionTimelineSample
Source§impl Debug for MotionTimelineSample
impl Debug for MotionTimelineSample
Source§impl PartialEq for MotionTimelineSample
impl PartialEq for MotionTimelineSample
impl StructuralPartialEq for MotionTimelineSample
Auto Trait Implementations§
impl Freeze for MotionTimelineSample
impl RefUnwindSafe for MotionTimelineSample
impl Send for MotionTimelineSample
impl Sync for MotionTimelineSample
impl Unpin for MotionTimelineSample
impl UnsafeUnpin for MotionTimelineSample
impl UnwindSafe for MotionTimelineSample
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