Linux VST3: Resize / host window does not change the size

The hosts plugin window does not change the size, when resizing VST3 plugins in Bitwig on Linux. Closing and reopen the plugin UI opens the window with the right size.

Latest JUCE 6 develop branch.

How are you resizing the plug-in? I’ve tested this with a fresh plug-in project with setResizable (true, true); and setResizable (true, false) with a timer running every 1s calling setSize() with a random new size and in all cases the Bitwig host window is resized correctly. (Bitwig Studio 3.3.3 on Ubuntu 18.04 using the tip of the develop branch).

I did notice however that there were occasional painting issues where the new window wasn’t being completely painted on resize and there is a fix for this on develop:

Thanks for looking at this. It seems to work if we set setResizable(true, true) in the constructor. But it does not work anymore if we are using following work around with the timer that makes the plugin render in the right size in macOS reaper or live:

The best solution may would be a fix for setResizable(true, true) so that we can restore a plugin size when open the plugin view in reaper and that the plugin does not fill the whole space automatically. What do you think?

Is that workaround still required? I’ve just tested a fresh VST3 plug-in project in Reaper on both macOS and Windows with:

setResizable (true, true);
getConstrainer()->setFixedAspectRatio (1.5);

setSize (300, 200);

in its constructor and placing it in an FX window will correctly resize the window to the plug-in’s size when the editor is opened and won’t resize the plug-in to fill the window as that thread mentions.

Reaper will resize the editor when dragging the window edges and not just the corner resizer, but this is the correct behaviour as the VST3 spec provides a way for the the host to resize the plug-in window via onSize() which wasn’t present in VST2.

I can still reproduce the issue with the latest JUCE 6 develop with your example code.

I do following:

  1. Load a new plug-in instance
  2. Scale the plugin and make it smaller than the window (make sure you don’t scale the window).
  3. Select another plugin (you can also change the window size here)
  4. Select our plug-in again
    → the plug-in scales up to the window (see screenshot)

The timer solution fixes this.

edit: Maybe because reaper thinks the plugin can’t be scaled. I start to think this is some kind of reaper feature. It’s odd, because the same thing works with VST2 plugins.

I’m still struggling to reproduce this, or maybe I’m just misunderstanding what the problem is. Can you send a screen recording of the issue?