A MIDI message container. More...
#include <MIDIMessage.h>
| Public Types | 
| Public Member Functions | |
| MIDIMessage (const MIDIMessage &other) | |
| Copy constructor.  More... | |
| MIDIMessage & | operator= (const MIDIMessage &other) | 
| Assignment operator.  More... | |
| void | from_raw (uint8_t *buf, int buf_len) | 
| Set this MIDIMessage to a raw MIDI message.  More... | |
| MIDIMessageType | type () | 
| Read the message type.  More... | |
| int | channel () | 
| Read the channel number.  More... | |
| int | key () | 
| Read the key ID.  More... | |
| int | velocity () | 
| Read the velocity.  More... | |
| int | value () | 
| Read the controller value.  More... | |
| int | pressure () | 
| Read the aftertouch pressure.  More... | |
| int | controller () | 
| Read the controller number.  More... | |
| int | program () | 
| Read the program number.  More... | |
| int | pitch () | 
| Read the pitch value.  More... | |
| Static Public Member Functions | |
| static MIDIMessage | NoteOff (int key, int velocity=127, int channel=0) | 
| Create a NoteOff message.  More... | |
| static MIDIMessage | NoteOn (int key, int velocity=127, int channel=0) | 
| Create a NoteOn message.  More... | |
| static MIDIMessage | PolyphonicAftertouch (int key, int pressure, int channel=0) | 
| Create a PolyPhonic Aftertouch message.  More... | |
| static MIDIMessage | ControlChange (int control, int value, int channel=0) | 
| Create a Control Change message.  More... | |
| static MIDIMessage | ProgramChange (int program, int channel=0) | 
| Create a Program Change message.  More... | |
| static MIDIMessage | ChannelAftertouch (int pressure, int channel=0) | 
| Create a Channel Aftertouch message.  More... | |
| static MIDIMessage | PitchWheel (int pitch=0, int channel=0) | 
| Create a Pitch Wheel message.  More... | |
| static MIDIMessage | AllNotesOff (int channel=0) | 
| Create an All Notes Off message.  More... | |
| static MIDIMessage | SysEx (uint8_t *data, int len) | 
| Create a SysEx message.  More... | |
A MIDI message container.
Definition at line 51 of file MIDIMessage.h.
| enum MIDIMessageType | 
MIDI Message Types.
Definition at line 255 of file MIDIMessage.h.
| MIDIMessage | ( | const MIDIMessage & | other | ) | 
Copy constructor.
Definition at line 66 of file MIDIMessage.h.
| 
 | static | 
Create an All Notes Off message.
| channel | Channel (0-15, default 0) | 
Definition at line 235 of file MIDIMessage.h.
| int channel | ( | ) | 
Read the channel number.
Definition at line 355 of file MIDIMessage.h.
| 
 | static | 
Create a Channel Aftertouch message.
| pressure | Pressure | 
| channel | Key channel (0-15, default 0) | 
Definition at line 203 of file MIDIMessage.h.
| 
 | static | 
Create a Control Change message.
| control | Controller ID | 
| value | Controller value (0-127) | 
| channel | Controller channel (0-15, default 0) | 
Definition at line 171 of file MIDIMessage.h.
| int controller | ( | ) | 
Read the controller number.
Definition at line 435 of file MIDIMessage.h.
| void from_raw | ( | uint8_t * | buf, | 
| int | buf_len | ||
| ) | 
Set this MIDIMessage to a raw MIDI message.
| buf | is a true MIDI message (not USBMidi message) | 
| buf_len | size of message | 
Definition at line 95 of file MIDIMessage.h.
| int key | ( | ) | 
| 
 | static | 
Create a NoteOff message.
| key | Key ID | 
| velocity | Key velocity (0-127, default = 127) | 
| channel | Key channel (0-15, default 0) | 
Definition at line 120 of file MIDIMessage.h.
| 
 | static | 
Create a NoteOn message.
| key | Key ID | 
| velocity | Key velocity (0-127, default = 127) | 
| channel | Key channel (0-15, default 0) | 
Definition at line 137 of file MIDIMessage.h.
| MIDIMessage& operator= | ( | const MIDIMessage & | other | ) | 
Assignment operator.
Definition at line 74 of file MIDIMessage.h.
| int pitch | ( | ) | 
Read the pitch value.
Definition at line 467 of file MIDIMessage.h.
| 
 | static | 
Create a Pitch Wheel message.
| pitch | Pitch (-8192 - 8191, default = 0) | 
| channel | Channel (0-15, default 0) | 
Definition at line 219 of file MIDIMessage.h.
| 
 | static | 
Create a PolyPhonic Aftertouch message.
| key | Key ID | 
| pressure | Aftertouch pressure (0-127) | 
| channel | Key channel (0-15, default 0) | 
Definition at line 154 of file MIDIMessage.h.
| int pressure | ( | ) | 
Read the aftertouch pressure.
Definition at line 415 of file MIDIMessage.h.
| int program | ( | ) | 
Read the program number.
Definition at line 452 of file MIDIMessage.h.
| 
 | static | 
Create a Program Change message.
| program | Program ID | 
| channel | Channel (0-15, default 0) | 
Definition at line 187 of file MIDIMessage.h.
| 
 | static | 
Create a SysEx message.
| data | SysEx data (including 0xF0 .. 0xF7) | 
| len | SysEx data length | 
Definition at line 245 of file MIDIMessage.h.
| MIDIMessageType type | ( | ) | 
| int value | ( | ) | 
Read the controller value.
Definition at line 398 of file MIDIMessage.h.
| int velocity | ( | ) |