pub struct ScaleSequence {
pub tonic: PitchClass,
pub scale: ScaleKind,
pub direction: SequenceDirection,
pub octave: Octave,
pub length: usize,
}Expand description
ScaleSequences allow for the creation of note-mapping patterns from common musical scales
Fields§
§tonic: PitchClassthe tonic of the scale
scale: ScaleKindthe supported scale kind, which determines intervals used
direction: SequenceDirectionare the notes ascending or descending?
octave: Octavewhat is the octave of the tonic where the sequence begins?
length: usizehow notes do we want the sequence to produce?
Implementations§
Source§impl ScaleSequence
impl ScaleSequence
Sourcepub fn as_midi_notes(&self) -> Vec<u8> ⓘ
pub fn as_midi_notes(&self) -> Vec<u8> ⓘ
Uses the field config values from self to produce a Vec
Trait Implementations§
Source§impl Clone for ScaleSequence
impl Clone for ScaleSequence
Source§fn clone(&self) -> ScaleSequence
fn clone(&self) -> ScaleSequence
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ScaleSequence
impl Debug for ScaleSequence
Source§impl Default for ScaleSequence
impl Default for ScaleSequence
impl Copy for ScaleSequence
Auto Trait Implementations§
impl Freeze for ScaleSequence
impl RefUnwindSafe for ScaleSequence
impl Send for ScaleSequence
impl Sync for ScaleSequence
impl Unpin for ScaleSequence
impl UnwindSafe for ScaleSequence
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