LinnStrument Support Page

For Developers of MIDI Sound Generators:

How to add MPE Capability

If you are a developer of MIDI sound generators and would like to add MPE (Multidimensional Polyphonic Expression) compatibility, this page will give you some help. MPE is pretty straightforward:

Each note's messages are sent on a unique MIDI channel, rotating through a contiguous block of "Per-Note" channels. The per-note messages sent over each channel are limited to Note On, Note Off, Channel Pressure (for finger pressure), Pitch Bend (for x-axis movement) and CC74 (for Y-axis movement).

Messages that apply to all voices (such as Sustain Pedal (CC64), Volume (CC7), Program Change, etc.) are sent over a separate "Master" channel.  An alternative implementation is to use no Master channel and to send these common messages over all of the Per-Note channels, in which case the receiver will recognize all messages other than the 5 per-note messages as common to all voices, regardless of the channel over which it is received.

So the main work is:

1) routing each incoming Per-Note channel to its own voice, listening only for the above 5 per-note messages, and

2) routing all other received messages, regardless of channel, to all voices.

MPE has already been implemented in lots of MIDI sound generators. The most popular MPE implementation in plug-in software instruments is for each channel to act as a one-channel polyphonic sound generator, thereby working fine with either single-channel or MPE controllers. For example, if normal one-channel polyphonic messages are received from a traditional MIDI keyboard, the sound generator works as a single-channel polyphonic sound generator. Or if messages are received from an MPE controller on multiple channels with each note on a separate channel, it also works fine for MPE operation. There is no need to define which channels are received, just listen to all channels and the host DAW will send you one, some or all channels. If a Pitch Bend Range message is received--useful for changing between the common +/- 2 semitone range of traditional MIDI keyboards and the default +/- 48 semitone range of MPE controllers--it simply follows the rule of applying to all voices. That said, it would also be helpful to give users a simple way to change the Pitch Bend Range manually, and preferably globally so they don't have to change it after selecting each new preset.

Note that some DAWs (like Ableton Live) reassign all received messages to the track's assigned MIDI channel, thereby preventing MPE plug-ins from receiving the necessary multiple channels.

If you are adding MPE to a standalone software instrument (not a plug-in) or a hardware instrument, you'll need to provide a UI for the user to select single-channel or MPE mode. A simple way to do this is to permit the Receive Channel parameter to include options for single channel 1 through single-channel 16, or OMNI (all channels mixed together without channel information) or MPE (implemented as described above). And in case someone wishes to send two MPE streams as in split keyboard play, it would be helpful to be able to select the range of received channels. That would permit, for example, your synth to listen on channels 1-8 (from the MPE controller's left split) and another synth to listen on channels 9-16 from the MPE controller's right split).

If you have any questions, you're welcome to contact me.

- Roger

Roger Linn Design  •  Berkeley, CA, USA

Roger Linn Design  •  Berkeley, CA, USA