VST3 Show Host Context Menu for a parameter

VST3 supports host context menus for parameters:

https://steinbergmedia.github.io/vst3_doc/vstinterfaces/contextmenu.html

I want to show the host context menu for a parameter when the user makes a right click on a slider. The host then shows something related to the parameter, for example a MIDI learn function.

Is this already supported in JUCE or is there a solution for this?

I might be mistaken, but I think this is actually for instances when you create your GUI with the VST framework?
Looking at the IPlugView suggests that and the comment in the code example you linked:

// this will be called if the user has executed one of the menu items of the Plug-in.
// It won't be called for items of the host.

Thanks for the answer. Yes, it looks like it’s some kind of feature in the plugininterface. The interesting part is following:

A Plug-in can ask the host to create a context menu for a given exported Parameter ID or a generic context menu.
The host may pre-fill this context menu with specific items regarding the parameter ID like “Show automation for parameter”, “MIDI learn” etc…

This is a nice and useful feature. It looks like it’s possible to ask the host for context menu entries for a specific parameter. There are plugins that already support this feature and a user already asked for this.

I think we can’t ignore it. It’s a part of the VST3 workflow and some moderne hosts already support this.

What do you think? Any input is welcome.

Ah, I missed that. Sounds cool. I don’t think this is possible yet. Something for the juce team to consider I guess

It looks to me like some management feature requests that breaks all architecture rules. I hope it’s possible to add this in juce :slight_smile:

Is this possible in the meantime? I read somewhere that host context menus now work in the JUCE wrapper.

Yes, it is possible using getContextMenuForParameter().

You can use it a juce::PopupMenu or let the host open a popup menu.

2 Likes

Ohh, yes. Thanks!