Posted on 3 Comments

Sample Creators: About MPE Support in DecentSampler

Hi everyone!

Over the past year, MIDI Polyphonic Expression (MPE) support has been slowly evolving in DecentSampler. In fact, everything I’m discussing in this blog post has actually been in the sampler since version 1.11.6, but I haven’t documented it because I consider this functionality to be in alpha. Speaking of which, I don’t think anyone should make use of any of these features in commercial sample libraries until all of the kinks have been ironed out. As I work towards a stable feature set, I’m seeking feedback from sample library developers to ensure these new features meet your needs and enable more expressive virtual instruments.

New MPE Modulators & MPE Mode

The MPE functionality introduced in 1.11.6 consists of two new modulators that respond to MPE data:

  1. mpeTimbre – Responds to the timbre/slide dimension of MPE (CC74)
  2. mpePressure – Responds to per-note pressure messages

Before we can talk about using either of these, it’s important to know that you need to turn on MPE Mode in the File > Instrument Settings dialog box.

Working with mpeTimbre

The mpeTimbre modulator allows you to map the timbre on MPE controllers to various parameters. Here’s a practical example that maps timbre to filter frequency:

<mpeTimbre modAmount="0.5" scope="voice">
      <binding type="effect" level="group" groupIndex="0" effectIndex="0" parameter="FX_FILTER_FREQUENCY" 
        modBehavior="add"
        translation="table" 
        translationTable="0,33;0.3,150;0.4,450;0.5,1100;0.7,4100;0.9,11000;1.0001,22000"  />
    </mpeTimbre>
Code language: HTML, XML (xml)

This example uses a translation table to create a non-linear response curve, making the filter frequency changes more musical and intuitive.

Working with mpePressure

The mpePressure modulator responds to per-note pressure, enabling dynamic control over parameters based on how hard a key is pressed after the initial note-on. Here’s an example that maps pressure to amplitude:

<mpePressure modAmount="0.5" scope="voice">
      <binding type="amp" level="group" groupIndex="0" effectIndex="0" parameter="AMP_VOLUME" 
        modBehavior="set"
        translation="linear"
        translationOutputMin="0.5"
        translationOutputMax="1"  />
    </mpePressure>Code language: HTML, XML (xml)

This configuration allows for expressive volume control per note, with pressure scaling the volume between 50% and 100% of the original level.

Example Files

You can download a simple example file here:

Share Your Feedback

As I refine these features, I’m particularly interested in knowing if these modulators seem like reasonable way to approach MPE within DecentSampler. Specifically, I’m curious about:

  1. How you might use these modulators in your sample libraries
  2. Additional parameters or controls you’d find useful
  3. Any edge cases or specific scenarios we should test
  4. Suggestions for improving the XML syntax and structure

Please share your thoughts, suggestions, and any issues you encounter in the comments section of this blog post. Your input will help shape these features and ensure they meet the needs of the sample library development community.

All the best,
Dave

3 thoughts on “Sample Creators: About MPE Support in DecentSampler

  1. Hi, Is there any way to set/code the DS keyboard so Middle C, MIDI note 60, maps to C4 on the Decent Sampler Keyboard (C4, 256 hz in scientific pitch notation), or C3, as per the Yamaha keyboard standard?

    1. When I first got started with the project, I decided to use the octave number system that was used by Ableton and Kontakt. It was only later that I realized that neither of them adhered to the scientific pitch notation. Unfortunately, I’m not sure it’s a good idea to add a user control for this. The reason is that within sample files (for attributes such as loNote and hiNote), you can specify MIDI notes using that same note-octavenumber notation (e.g. “C4, D3”) as well. If I allowed users to change the mapping on the keyboard, it could get quite confusing if the engine itself used a different standard for decoding it.

  2. Been having a play with these modulators and I like the way they’re implemented. Simply done and fit into the existing paradigms nicely! I’d love a way to be able to store MPE settings like per-note pitch bend range in an instrument file. I use an Osmose as my primary MPE controller and I find myself changing the ranges for each patch a lot depending on how I use it – so with a pad sound played with both hands I turn down the per-note bend as it’s hard to control, but a mono lead sound has a much wider per not bend. It would be nice to be able to do the same in DS!

Leave a Reply

Your email address will not be published. Required fields are marked *