This class mimicks the interface of MIDIOut, so you don`t have to send raw MIDI messages.
Instances are obtained with VSTPluginController: -midi. You should never need to create instances of this class yourself!
It is used internally by Pbinds of event type \vst_midi
(see VSTPluginController: Sequencing), but it can be used in other situations as well, e.g. for playing a VSTi with a MIDI keyboard.
NOTE: MIDI pitches can be Floats! The fractional part is converted to cents and passed as the
detune
argument to
-sendMidi. This is not part of the MIDI standard and not all VST instruments actually support it!
All methods have a corresponding *Msg
version which returns a raw OSC message, so they can be scheduled as bundles.
VSTPluginMIDIProxy.new(theOwner)
.bend(chan, val: 8192)
.bendMsg(chan, val: 8192)
.control(chan, ctlNum: 7, val: 64)
.controlMsg(chan, ctlNum: 7, val: 64)
.noteOff(chan, note: 60, veloc: 64)
.noteOffMsg(chan, note: 60, veloc: 64)
.noteOn(chan, note: 60, veloc: 64)
.noteOnMsg(chan, note: 60, veloc: 64)
.polyTouch(chan, note: 60, val: 64)
.polyTouchMsg(chan, note: 60, val: 64)
.program(chan, num: 1)
.smpte(frames: 0, seconds: 0, minutes: 0, hours: 0, frameRate: 3)
.touch(chan, val: 64)
.uid = value
.write(len, hiStatus, loStatus, a: 0, b: 0, detune)
.writeMsg(len, hiStatus, loStatus, a: 0, b: 0, detune)