pub enum LiveAudioEvent {
Xrun {
frames: u32,
max_frames: u32,
},
DroppedControlEvents {
count: u64,
},
DroppedAudioEvents {
count: u64,
},
ProcessorParamSet {
offset: u32,
param: u32,
value: f64,
},
ProcessorMidi {
offset: u32,
bytes: [u8; 3],
len: u8,
},
}Expand description
Owned audio event moved from the audio callback to the control thread.
Variants§
Xrun
An audio callback received more frames than the prepared maximum.
DroppedControlEvents
Control-to-audio queue dropped events under backpressure.
DroppedAudioEvents
Audio-to-control queue dropped events under backpressure.
ProcessorParamSet
A processor emitted a parameter-set event.
Fields
ProcessorMidi
A processor emitted a short MIDI message.
Implementations§
Source§impl LiveAudioEvent
impl LiveAudioEvent
Sourcepub fn from_processor_event(event: BlockEvent<'_>) -> Option<Self>
pub fn from_processor_event(event: BlockEvent<'_>) -> Option<Self>
Captures a processor-emitted BlockEvent as a live audio event.
Returns None for events that are not carried back to the control
thread (long MIDI, note-on, and note-off).
Sourcepub fn to_diagnostic_packet(self) -> StreamPacket
pub fn to_diagnostic_packet(self) -> StreamPacket
Renders the event as a stream diagnostic packet for the control thread.
Trait Implementations§
Source§impl Clone for LiveAudioEvent
impl Clone for LiveAudioEvent
Source§fn clone(&self) -> LiveAudioEvent
fn clone(&self) -> LiveAudioEvent
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for LiveAudioEvent
Source§impl Debug for LiveAudioEvent
impl Debug for LiveAudioEvent
Source§impl PartialEq for LiveAudioEvent
impl PartialEq for LiveAudioEvent
Source§fn eq(&self, other: &LiveAudioEvent) -> bool
fn eq(&self, other: &LiveAudioEvent) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for LiveAudioEvent
Auto Trait Implementations§
impl Freeze for LiveAudioEvent
impl RefUnwindSafe for LiveAudioEvent
impl Send for LiveAudioEvent
impl Sync for LiveAudioEvent
impl Unpin for LiveAudioEvent
impl UnsafeUnpin for LiveAudioEvent
impl UnwindSafe for LiveAudioEvent
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