![]() |
wxMidi - A MIDI interface based on PortMidi
|
The only header file for wxMidi. More...
#include "wx/wxprec.h"
#include "wx/wx.h"
#include "portmidi.h"
#include "porttime.h"
#include <time.h>
Go to the source code of this file.
Classes | |
class | wxMidiMessage |
Abstract class representing a MIDI message. More... | |
class | wxMidiShortMessage |
wxMidiShortMessage represents a MIDI short message. More... | |
class | wxMidiSysExMessage |
Represents a system-exclusive MIDI message. More... | |
class | wxMidiDevice |
Abstract class representing a MIDI device. More... | |
class | wxMidiOutDevice |
Represents a MIDI stream on which MIDI data traffic can be sent. More... | |
class | wxMidiInDevice |
Represents a MIDI stream on which MIDI data traffic can be read. More... | |
class | wxMidiDatabaseGM |
A database for Midi GM (General MIDI Standard) instruments. More... | |
class | wxMidiSystem |
Class wxMidiSystem is the entry point to the wxMidi library. More... | |
class | wxMidiThread |
Helper class for internal use. More... | |
Macros | |
#define | __WXMIDI_H__ |
#define | wxMIDI_VERSION _T("2.0") |
Constants related to wxMidi version. | |
#define | wxMIDI_MAJOR 2 |
#define | wxMIDI_MINOR 0 |
#define | wxMidiDeviceID PmDeviceID |
Rename some data types inherited from portmidi. | |
#define | wxMidiTimestamp PmTimestamp |
#define | wxMidiPmMessage PmMessage |
#define | wxMidiPmEvent PmEvent |
#define | wxMIDI_CHANNEL(channel) (1<<(channel)) |
#define | PopulateWithPercussionInstr PopulateWithPercusionInstr |
Fix spelling error without changing the API, for backwards compatibility. | |
The only header file for wxMidi.
#define wxMIDI_CHANNEL | ( | channel | ) | (1<<(channel)) |
Macro to be used in method wxMidiInDevice::SetChannelMask(). This method requires a mask value that is a 16-bit bitfield with bits set to signal the appropriate channels. Macro wxMIDI_CHANNEL can assist in preparing this mask. For example, to set for receiving input only from channel 12, prepare the mask with
Multiple channels should be OR'd together, like
enum wxMidiError |
Error codes from portmidi and additional errors from wxMidi.
Enumerator | |
---|---|
wxMIDI_ERROR_HostError | No error. The requested operation succedeed. |
wxMIDI_ERROR_InvalidDeviceId | Portmidi reported a host error. You have to call wxMidiSystem::GetHostErrorText to get more details about the error. |
wxMIDI_ERROR_InsufficientMemory | Invalid device ID. The ID is out of range (less than zero or greater or equal than the value returned by wxMidiSystem::CountDevices. Or it is an input device and it is being used to construct a wxMidiOutDevice, or viceversa. Or the device is already opened |
wxMIDI_ERROR_BufferTooSmall | Insufficient memory. |
wxMIDI_ERROR_BufferOverflow | PortMidi reports a 'Buffer too small' error. You should close the device and reopen it specifying a greater buffersize value. |
wxMIDI_ERROR_BadPtr | PortMidi reported a 'Buffer overflow'. You should close the device and reopen it specifying a greater buffersize value. |
wxMIDI_ERROR_BadData | PortMidi reports a `Bad pointer error'. This should not happen as wxMidi deals with PmDevices inside objects wxMidiDevice, and so, user has no need to deal with pointers to PmDevices. |
wxMIDI_ERROR_InternalError | PortMidi reported an 'Invalid MIDI message Data' such as illegal MIDI data or a missing EOX. |
wxMIDI_ERROR_BufferMaxSize | Portmidi reported an 'Internal Error'. Sorry, no more information. |
wxMIDI_ERROR_AlreadyListening | Portmidi informs that 'buffer is already as large as it can be'. |
wxMIDI_ERROR_CreateThread | Informative error. A second call to method wxMidiInDevice::StartListening without previously calling method wxMidiInDevice::StopListening. The lisening thread is left active. |
wxMIDI_ERROR_StartThread | An error ocurred during a call to wxMidiInDevice::StartListening. The error ocurred while trying to create the wxThread object. |
wxMIDI_ERROR_BadSysExMsg_Start | An error ocurred during a call to wxMidiInDevice::StartListening. The error ocurred after successful creation of the wxThread object, while starting the thread execution. |
wxMIDI_ERROR_NoDataAvailable | The wxByte string received as parameter to create a wxMidiSysExMessage object does not start with 0xF0 (start-of-sysex status byte). |
wxMIDI_ERROR_TimeOut | You called method wxMidiInDevice::Read but there is no message waiting to be delivered. You have to call Read method only after an wxEVT_MIDI_INPUT event takes place or after the method wxMidiInDevice::Poll reports that there is a message waiting. |
enum wxMidiFilter |
Filter codes, renamed from portmidi.
enum wxMidiMsgType |
Identifies the MIDI message type.
Enumerator | |
---|---|
wxMIDI_UNDEFINED_MSG | Undefined (invalid wxMidiMessage object) |
wxMIDI_SHORT_MSG | Short message (wxMidiShortMessage) |
wxMIDI_SYSEX_MSG | SysEx message (wxMidiSysExMessage) |