pub enum Timing {
Metrical(u15),
Timecode(Fps, u8),
}
Expand description
The timing for an SMF file. This can be in ticks/beat or ticks/second.
Variants§
Metrical(u15)
Specifies ticks/beat as a 15-bit integer.
The length of a beat is not standard, so in order to fully describe the length of a MIDI
tick the MetaMessage::Tempo
event should be present.
Timecode(Fps, u8)
Specifies ticks/second by dividing a second into frames and then into subframes.
Therefore the length of of a tick is 1/fps/subframe
.
Trait Implementations§
impl Copy for Timing
impl Eq for Timing
impl StructuralPartialEq for Timing
Auto Trait Implementations§
impl Freeze for Timing
impl RefUnwindSafe for Timing
impl Send for Timing
impl Sync for Timing
impl Unpin for Timing
impl UnwindSafe for Timing
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more