pub struct Easing {
values: HashMap<AnimKey, Eased>,
}Expand description
Every keyed easing in the session.
Fields§
§values: HashMap<AnimKey, Eased>Implementations§
Source§impl Easing
impl Easing
Sourcepub fn animate(
&mut self,
tick: Tick,
key: AnimKey,
goal: f32,
over: Duration,
) -> Animated
pub fn animate( &mut self, tick: Tick, key: AnimKey, goal: f32, over: Duration, ) -> Animated
Where key’s easing stands, having aimed it at goal over over.
The first sight of a key answers the goal itself, so an affordance appears where it belongs rather than sliding in from nowhere. After that the value is read half a predicted frame ahead, which is what keeps the frame a goal changes on from answering the old value.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Easing
impl RefUnwindSafe for Easing
impl Send for Easing
impl Sync for Easing
impl Unpin for Easing
impl UnsafeUnpin for Easing
impl UnwindSafe for Easing
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