Enum midi_msg::SampleDumpMsg
source · [−]pub enum SampleDumpMsg {
Request {
sample_num: u16,
},
Header {
sample_num: u16,
format: u8,
period: u32,
length: u32,
sustain_loop_start: u32,
sustain_loop_end: u32,
loop_type: LoopType,
},
Packet {
running_count: u8,
data: Vec<u8>,
},
LoopPointsRequest {
sample_num: u16,
loop_num: LoopNumber,
},
LoopPointTransmission {
sample_num: u16,
loop_num: LoopNumber,
loop_type: LoopType,
start_addr: u32,
end_addr: u32,
},
}
Expand description
Used to request and transmit sampler data.
Used by UniversalNonRealTimeMsg::SampleDump
.
Variants
Request
Fields
sample_num: u16
The ID of the sample, between 0-16383.
Request that the receiver send the given sample.
Header
Fields
sample_num: u16
The ID of the sample, between 0-16383.
format: u8
period: u32
Sample period (1/sample rate) in nanoseconds, 0-2097151
length: u32
Sample length in words, 0-2097151
sustain_loop_start: u32
Sustain loop start point word number, 0-2097151
sustain_loop_end: u32
Sustain loop end point word number, 0-2097151
loop_type: LoopType
The first message in a sample dump, used to describe the data contained in the following packets.
Packet
Fields
running_count: u8
Running packet count, 0-127. Wraps back to 0
A single packet of sample data.
Use SampleDumpMsg::packet
to construct.
LoopPointsRequest
Request that the receiver return data about the loop points for a given sample.
LoopPointTransmission
Fields
sample_num: u16
The ID of the sample, between 0-16383.
loop_num: LoopNumber
loop_type: LoopType
start_addr: u32
Loop start address (in samples)
end_addr: u32
Loop end address (in samples)
Used to send additional loop points for a given sample.
Implementations
Trait Implementations
sourceimpl Clone for SampleDumpMsg
impl Clone for SampleDumpMsg
sourcefn clone(&self) -> SampleDumpMsg
fn clone(&self) -> SampleDumpMsg
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more