pub enum Message {
Show 18 variants
NoteOff(Channel, Note, Velocity),
NoteOn(Channel, Note, Velocity),
PolyphonicAftertouch(Channel, Note, U7),
ProgramChange(Channel, U7),
ChannelAftertouch(Channel, U7),
PitchWheelChange(Channel, U14),
ControlChange(Channel, ControlFunction, U7),
MtcQuarterFrame(U7),
SongPositionPointer(U14),
SongSelect(U7),
TuneRequest,
TimingClock,
Tick,
Start,
Continue,
Stop,
ActiveSensing,
Reset,
}Expand description
Represents the MIDI messages.
Variants§
NoteOff(Channel, Note, Velocity)
Note On message.
NoteOn(Channel, Note, Velocity)
Note Off message.
PolyphonicAftertouch(Channel, Note, U7)
Polyphonic aftertouch (poly-pressure) message.
ProgramChange(Channel, U7)
Program change message.
ChannelAftertouch(Channel, U7)
Channel aftertouch message.
PitchWheelChange(Channel, U14)
Pitchwheel message.
ControlChange(Channel, ControlFunction, U7)
Control Change (CC) message.
MtcQuarterFrame(U7)
MTC Quarter Frame message.
SongPositionPointer(U14)
Song Position Pointer message.
SongSelect(U7)
Song Select message.
TuneRequest
Tune Request message.
TimingClock
Timing Clock message.
Tick
Tick message.
Start
Start message.
Continue
Continue message.
Stop
Stop message.
ActiveSensing
Active Sensing message.
Reset
Reset message.
Implementations§
Source§impl Message
impl Message
Sourcepub fn into_packet(self, cable: CableNumber) -> UsbMidiEventPacket
pub fn into_packet(self, cable: CableNumber) -> UsbMidiEventPacket
Create a packet from the message.
Sourcepub fn code_index_number(&self) -> CodeIndexNumber
pub fn code_index_number(&self) -> CodeIndexNumber
Returns the code index number for a message.
Trait Implementations§
Source§impl TryFrom<&UsbMidiEventPacket> for Message
impl TryFrom<&UsbMidiEventPacket> for Message
Source§type Error = UsbMidiEventPacketError
type Error = UsbMidiEventPacketError
The type returned in the event of a conversion error.
impl Eq for Message
impl StructuralPartialEq for Message
Auto Trait Implementations§
impl Freeze for Message
impl RefUnwindSafe for Message
impl Send for Message
impl Sync for Message
impl Unpin for Message
impl UnwindSafe for Message
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