pub struct SpringDesc {
pub mass: f64,
pub stiffness: f64,
pub damping_ratio: f64,
}Expand description
Physical parameters of a damped spring.
damping_ratio is ζ: < 1 under-damped (overshoots), == 1 critically
damped (fastest settle without overshoot), > 1 over-damped.
Fields§
§mass: f64Mass of the moving body (> 0).
stiffness: f64Spring stiffness k (> 0); higher is snappier.
damping_ratio: f64Damping ratio ζ (> 0).
Trait Implementations§
Source§impl Clone for SpringDesc
impl Clone for SpringDesc
impl Copy for SpringDesc
Source§impl Debug for SpringDesc
impl Debug for SpringDesc
Source§impl PartialEq for SpringDesc
impl PartialEq for SpringDesc
impl StructuralPartialEq for SpringDesc
Auto Trait Implementations§
impl Freeze for SpringDesc
impl RefUnwindSafe for SpringDesc
impl Send for SpringDesc
impl Sync for SpringDesc
impl Unpin for SpringDesc
impl UnsafeUnpin for SpringDesc
impl UnwindSafe for SpringDesc
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> StorageAccess<T> for T
impl<T> StorageAccess<T> for T
Source§fn as_borrowed(&self) -> &T
fn as_borrowed(&self) -> &T
Borrows the value.
Source§fn into_taken(self) -> T
fn into_taken(self) -> T
Takes the value.