Jack2 1.9.6
|
Public Member Functions | |
JackPhysicalMidiInput (size_t buffer_size=1024) | |
void | Process (jack_nframes_t) |
void | SetPortBuffer (JackMidiBuffer *port_buffer) |
Protected Member Functions | |
virtual void | HandleBufferFailure (size_t, size_t) |
virtual void | HandleIncompleteMessage (size_t) |
virtual void | HandleInvalidStatusByte (jack_midi_data_t) |
virtual void | HandleUnexpectedSysexEnd (size_t) |
virtual void | HandleWriteFailure (size_t) |
virtual jack_nframes_t | Receive (jack_midi_data_t *, jack_nframes_t, jack_nframes_t)=0 |
Definition at line 28 of file JackPhysicalMidiInput.h.
void Jack::JackPhysicalMidiInput::HandleBufferFailure | ( | size_t | unbuffered_bytes, |
size_t | total_bytes | ||
) | [protected, virtual] |
Override to specify how to react when 1 or more bytes of a MIDI message are lost because there wasn't enough room in the input buffer. The first argument is the amount of bytes that couldn't be buffered, and the second argument is the total amount of bytes in the MIDI message. The default implementation calls 'jack_error' with a basic error message.
Definition at line 58 of file JackPhysicalMidiInput.cpp.
void Jack::JackPhysicalMidiInput::HandleIncompleteMessage | ( | size_t | bytes | ) | [protected, virtual] |
Override to specify how to react when a new status byte is received before all of the data bytes in a message are received. The argument is the number of bytes being discarded. The default implementation calls 'jack_error' with a basic error message.
Definition at line 66 of file JackPhysicalMidiInput.cpp.
void Jack::JackPhysicalMidiInput::HandleInvalidStatusByte | ( | jack_midi_data_t | status | ) | [protected, virtual] |
Override to specify how to react when an invalid status byte (0xf4, 0xf5, 0xfd) is received. The argument contains the invalid status byte. The default implementation calls 'jack_error' with a basic error message.
Definition at line 73 of file JackPhysicalMidiInput.cpp.
void Jack::JackPhysicalMidiInput::HandleUnexpectedSysexEnd | ( | size_t | bytes | ) | [protected, virtual] |
Override to specify how to react when a sysex end byte (0xf7) is received without first receiving a sysex start byte (0xf0). The argument contains the amount of bytes that will be discarded. The default implementation calls 'jack_error' with a basic error message.
Definition at line 80 of file JackPhysicalMidiInput.cpp.
void Jack::JackPhysicalMidiInput::HandleWriteFailure | ( | size_t | bytes | ) | [protected, virtual] |
Override to specify how to react when a MIDI message can not be written to the port buffer. The argument specifies the length of the MIDI message. The default implementation calls 'jack_error' with a basic error message.
Definition at line 87 of file JackPhysicalMidiInput.cpp.
virtual jack_nframes_t Jack::JackPhysicalMidiInput::Receive | ( | jack_midi_data_t * | , |
jack_nframes_t | , | ||
jack_nframes_t | |||
) | [protected, pure virtual] |
This method *must* be overridden to handle receiving MIDI bytes. The first argument is a pointer to the memory location at which the MIDI byte should be stored. The second argument is the last frame at which a MIDI byte was received, except at the beginning of the period when the value is 0. The third argument is the total number of frames in the period. The return value is the frame at which the MIDI byte is received at, or the value of the third argument is no more MIDI bytes can be received in this period.
void Jack::JackPhysicalMidiInput::Process | ( | jack_nframes_t | frames | ) |
Called to process MIDI data during a period.
Definition at line 94 of file JackPhysicalMidiInput.cpp.
void Jack::JackPhysicalMidiInput::SetPortBuffer | ( | JackMidiBuffer * | port_buffer | ) | [inline] |
Set the MIDI buffer that will receive incoming messages.
Definition at line 137 of file JackPhysicalMidiInput.h.