Some Linux DAWs/hosts, such as Renoise, handle VST3 scaling differently, causing JUCE plugins to render cropped; especially on high DPI screens.
I was able to fix this issue by adding
void setScaleFactor(float newScale) override;
to PluginEditor.h
adding
void QDelayAudioProcessorEditor::setScaleFactor(float /* newScale */)
{
juce::AudioProcessorEditor::setScaleFactor(audioProcessor.scale);
}
to PluginEditor.cpp while also removing any lines containing Desktop::getInstance().setGlobalScaleFactor(audioProcessor.scale); in that file
and changing QDelayAudioProcessor::setScale to
void QDelayAudioProcessor::setScale(float s)
{
scale = s;
saveSettings();
if(auto* editor = dynamic_cast<QDelayAudioProcessorEditor*>(this->getActiveEditor()))
editor->setScaleFactor(scale);
}
This allows the host to automatically call the scale upon loading the GUI and handle scaling changes while providing a consistent experience across various hosts and platforms.
Some Linux DAWs/hosts, such as Renoise, handle VST3 scaling differently, causing JUCE plugins to render cropped; especially on high DPI screens.
I was able to fix this issue by adding
to
PluginEditor.hadding
to
PluginEditor.cppwhile also removing any lines containingDesktop::getInstance().setGlobalScaleFactor(audioProcessor.scale);in that fileand changing
QDelayAudioProcessor::setScaletoThis allows the host to automatically call the scale upon loading the GUI and handle scaling changes while providing a consistent experience across various hosts and platforms.