Struct instrument::mode::Mono [] [src]

pub struct Mono(pub MonoKind, pub Vec<NoteHz>);

Monophonic playback.

Methods

impl Mono
[src]

fn retrigger() -> Mono

Construct a default Retrigger mono mode.

fn legato() -> Mono

construct a default Legato mono mode.

Trait Implementations

impl PartialEq for Mono
[src]

fn eq(&self, __arg_0: &Mono) -> bool

This method tests for self and other values to be equal, and is used by ==. Read more

fn ne(&self, __arg_0: &Mono) -> bool

This method tests for !=.

impl Debug for Mono
[src]

fn fmt(&self, __arg_0: &mut Formatter) -> Result

Formats the value using the given formatter.

impl Clone for Mono
[src]

fn clone(&self) -> Mono

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)
1.0.0

Performs copy-assignment from source. Read more

impl Mode for Mono
[src]

fn note_on<NFG>(&mut self, note_hz: NoteHz, note_vel: NoteVelocity, detune: f32, note_freq_gen: &NFG, voices: &mut [Voice<NFG::NoteFreq>]) where NFG: NoteFreqGenerator

Handle a note_on event.

fn note_off<NFG>(&mut self, note_hz: NoteHz, detune: f32, note_freq_gen: &NFG, voices: &mut [Voice<NFG::NoteFreq>]) where NFG: NoteFreqGenerator

Handle a note_off event.

fn stop(&mut self)

Handle a stop event.