Dorico MIDI Channel Routing with Multitimbral VST Plugin

I’m developing a multi-timbral VST3 plugin using the DPF (DISTRHO Plugin Framework) and I’m having trouble getting Dorico to respect MIDI channel assignments in the endpoint setup. The plugin has 4 channels (Pulse 1, Pulse 2, Triangle, Noise) and I’ve assigned each instrument to a separate MIDI channel (1–4) in Dorico’s endpoint setup. However, all notes arrive on channel 0 regardless of which instrument is playing.

I’ve confirmed with logging inside my run() function that the raw status bytes always show channel 0. The same plugin correctly receives notes on different channels in Carla. I’ve also tried setting kIsMultiTimbral (bit 3) in class_flags in the factory’s get_class_info_2 and get_class_info_utf16 — no change.

Is there something specific a VST3 plugin needs to declare or implement for a host like Dorico to respect multi-channel MIDI routing?

Have you already heard about Units in VST3? An AI Google search delivers following result:

VST3 Units are logical subdivisions within a VST3 plugin (e.g., separating EQ, Compressor, and Reverb sections) designed to improve workflow and organization. Their primary purpose is to expose internal structure, manage complex multi-timbral instruments, enable specific program lists per unit, and map parameter automation to specific functional areas.

Key purposes and advantages of VST3 units include:

  • Structural Organization: Units allow complex plugins to be broken down into smaller, logical, and named sections, enhancing the GUI and parameter management.
  • Program List Management: Units support individual program lists, meaning different sections of a plugin can have their own presets.
  • Improved Automation: Parameters can be linked to specific units, making it clearer to find and automate settings within complex plugins.
  • Multi-timbral Support: Essential for multi-channel instruments, allowing, for example, each MIDI track or channel to be associated with a specific unit.
  • Host Integration: Helps the host DAW synchronize its own parameter view with the plugin’s internal structure.

Here is the documentation for VST3 Units.

Really helpful, thanks! I guess the question now is “does Dorico require IUnitInfo for multi-channel MIDI routing to work?” It looks like getUnitByBus might be it. I’d have to bolt that on on top of DPF though so I want to be sure before I go uprooting things

This is what another AI search revealed:

The IUnitInfo interface in the VST3 SDK is used by plugins to organize parameters into hierarchical units or groups, such as separating oscillator settings from filter settings, which allows hosts like Cubase to display them in a structured way.

  • Missing IUnitInfo Warnings: If you are developing a plugin using framework like JUCE and receive a validation error that IUnitInfo is missing, it means the plugin has not implemented the VST3 unit structure. While not strictly necessary for a plugin to function, it is required for proper organization in advanced hosts.
  • Cubase Integration: While some hosts might not directly expose this unit structure, Cubase uses IUnitInfo for advanced features like “Create Drum Map from Instrument,” which allows for quick mapping of multi-output VST3 instruments.
  • Alternative Interfaces: In some cases, IUnitInfo can be used to handle program changes and unit-specific parameter management, particularly for multi-timbral instruments.

If a plugin lacks IUnitInfo, it may still work, but it may not show sub-categories in the plugin editor or provide specific parameter mapping functionalities.

Note: This search was on Cubase and VST3 Units, but since Dorico’s audio engine is derived from Cubase, the same applies to Dorico as well.

1 Like

IUnitInfo is required for Dorico to respect endpoint channel assignments, and critically, channel_count in getBusInfo for the event bus must match the number of MIDI channels a plugin uses, because Dorico uses that value to determine how many times to call get_unit_by_bus.

1 Like