pub struct MidiEvent {
pub data: [u8; 3],
pub delta_frames: i32,
pub live: bool,
pub note_length: Option<i32>,
pub note_offset: Option<i32>,
pub detune: i8,
pub note_off_velocity: u8,
}
Expand description
A midi event.
These are sent to the plugin before Plugin::processing()
or Plugin::processing_f64()
is
called.
Fields§
§data: [u8; 3]
The raw midi data associated with this event.
delta_frames: i32
Number of samples into the current processing block that this event occurs on.
E.g. if the block size is 512 and this value is 123, the event will occur on sample
samples[123]
.
live: bool
This midi event was created live as opposed to being played back in the sequencer.
This can give the plugin priority over this event if it introduces a lot of latency.
note_length: Option<i32>
The length of the midi note associated with this event, if available.
note_offset: Option<i32>
Offset in samples into note from note start, if available.
detune: i8
Detuning between -63 and +64 cents.
note_off_velocity: u8
Note off velocity between 0 and 127.
Trait Implementations§
source§impl WriteIntoPlaceholder for MidiEvent
impl WriteIntoPlaceholder for MidiEvent
source§fn write_into(&self, out: &mut PlaceholderEvent)
fn write_into(&self, out: &mut PlaceholderEvent)
writes an event into the given placeholder memory location