pub struct Clock { /* private fields */ }Implementations§
Source§impl Clock
impl Clock
pub fn new(tick_rate: f64) -> Result<Self, ClockError>
pub fn tick_rate(&self) -> f64
pub fn tick_dt(&self) -> f64
pub fn speed(&self) -> f32
pub fn set_speed(&mut self, speed: f32)
pub fn paused(&self) -> bool
pub fn pause(&mut self)
pub fn resume(&mut self)
pub fn hit_stop(&mut self, stop: HitStop)
pub fn dip(&self) -> Option<Dip>
pub fn scale(&self) -> f32
pub fn time(&self) -> f64
pub fn ticks(&self) -> u64
pub fn alpha(&self) -> f32
pub fn advance(&mut self, real: f32) -> Tick
pub fn sound_rate(&self, tie: f32) -> f32
pub fn save(&self) -> [u8; 56]
pub fn restore(bytes: &[u8]) -> Result<Self, ClockError>
Trait Implementations§
impl Copy for Clock
impl StructuralPartialEq for Clock
Auto Trait Implementations§
impl Freeze for Clock
impl RefUnwindSafe for Clock
impl Send for Clock
impl Sync for Clock
impl Unpin for Clock
impl UnsafeUnpin for Clock
impl UnwindSafe for Clock
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