Controls a physical MIDI output device. More...
|void||sendMessageNow (const MidiMessage &message)|
|Makes this device output a midi message. More...|
|void||sendBlockOfMessages (const MidiBuffer &buffer, double millisecondCounterToStartAt, double samplesPerSecondForBuffer)|
|This lets you supply a block of messages that will be sent out at some point in the future. More...|
|Gets rid of any midi messages that had been added by sendBlockOfMessages(). More...|
|Starts up a background thread so that the device can send blocks of data. More...|
|Stops the background thread, and clears any pending midi events. More...|
|static StringArray||getDevices ()|
|Returns a list of the available midi output devices. More...|
|static int||getDefaultDeviceIndex ()|
|Returns the index of the default midi output device to use. More...|
|static MidiOutput *||openDevice (int deviceIndex)|
|Tries to open one of the midi output devices. More...|
|static MidiOutput *||createNewDevice (const String &deviceName)|
|This will try to create a new midi output device (Not available on Windows). More...|
Controls a physical MIDI output device.
- See also
Constructor & Destructor Documentation
Member Function Documentation
Returns the index of the default midi output device to use.
This refers to the index in the list returned by getDevices().
Tries to open one of the midi output devices.
This will return a MidiOutput object if it manages to open it. You can then send messages to this device, and delete it when no longer needed.
If the device can't be opened, this will return a null pointer.
deviceIndex the index of a device from the list returned by getDevices()
- See also
This will try to create a new midi output device (Not available on Windows).
This will attempt to create a new midi output device that other apps can connect to and use as their midi input.
Returns nullptr if a device can't be created.
deviceName the name to use for the new device
|void MidiOutput::sendMessageNow||(||const MidiMessage &||message||)|
Makes this device output a midi message.
- See also
|void MidiOutput::sendBlockOfMessages||(||const MidiBuffer &||buffer,|
This lets you supply a block of messages that will be sent out at some point in the future.
The MidiOutput class has an internal thread that can send out timestamped messages - this appends a set of messages to its internal buffer, ready for sending.
This will only work if you've already started the thread with startBackgroundThread().
A time is specified, at which the block of messages should be sent. This time uses the same time base as Time::getMillisecondCounter(), and must be in the future.
The samplesPerSecondForBuffer parameter indicates the number of samples per second used by the MidiBuffer. Each event in a MidiBuffer has a sample position, and the samplesPerSecondForBuffer value is needed to convert this sample position to a real time.
Gets rid of any midi messages that had been added by sendBlockOfMessages().
Starts up a background thread so that the device can send blocks of data.
Call this to get the device ready, before using sendBlockOfMessages().
Stops the background thread, and clears any pending midi events.
- See also
The documentation for this class was generated from the following file: