JUCE 4.2, latest develop:
We’re having a hell of a time adding interface scaling to our plug-ins. We’ve been using the SoundRadix fork for a while, but ran into this bug. We’ve switched to the main develop branch to try to troubleshoot this.
So, we have a PluginEditor. We also have an OpenGLContext (continuous repaint enabled) that is attached to the editor. To do interface scaling, we’re resizing the window and applying an affine transform to scale the component.
setSize(getPluginMainWidth() * getInterfaceScale(), getPluginMainHeight() * getInterfaceScale()); setTransform(AffineTransform::scale(getInterfaceScale()));
This scaling code works perfectly without the OpenGLContext in every single host that we’ve tested.
When OpenGLContext is enabled, everything breaks. The interface is rendered at a vertical offset (but clicking on the interface shows that controls are positioned where they should be). This occurs on Windows and OS X.
On Windows, the following SoundRadix commit fixes this issue:
With this commit, we’re able to use OpenGLContext with our resizing code in every tested host.
On OS X, we have found nothing that works. The SoundRadix patch does not fix it for us. JUCE 4.2.1 master and develop branches do not work either.
We require OpenGLContext for our plug-ins, or else we face a number of rendering issues.