ryukau / VSTPlugins

Uhhyou Plugins VST 3 repository.

Home Page:https://ryukau.github.io/VSTPlugins/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

VST3 GUI does not display in Linux

tank-trax opened this issue · comments

I am using Debian Buster and can build the VST locally but cannot load the release build due to differing libxcb-util versions

for the prebuilt version

ldd WaveCymbal.so 
libxcb-util.so.1 => not found

for the locally built version

ldd WaveCymbal.so 
libxcb-util.so.0 => /lib/x86_64-linux-gnu/libxcb-util.so.0 (0x00007fd877e9d000)

I installed the libxcb-util.so.1 and can load both the locally built version and release build to see if there was a difference, however neither displays the GUI in either Reaper or Bitwig.

Hi, tank-trax. Thanks for the report. It seems like there are 2 separate issues.

libxcb-util version

I use Ubuntu 18.04 on GitHub Actions to build plugins. From the result of package search, it seems like debian and ubuntu have some different libxcb-util package.

Also VST 3 SDK documentation says it is only tested for ubuntu or mint. So to avoid libxcb-util version issue, please build it from source.

GUI on Linux

I'll look into it. I guess it's time to fix this issue. But I'm not confident if I could solve this issue in near future. Any help is welcome.

Currently GUI for Linux build is disabled in code, because it lead to crash on reaper. To enable it, open PluginName/source/plugcontroller.cpp then comment out #ifndef LINUX in createView().

IPlugView *PLUGIN_API PlugController::createView(const char *name)
{
// #ifndef LINUX // Comment out this.
  if (name && strcmp(name, "editor") == 0) {
    auto plugEditor = new Vst::PlugEditor(this);
    plugEditor->remember();
    editor.push_back(plugEditor);
    return plugEditor;
  }
// #endif // Comment out this.
  return 0;
}

I've been following your Synths for a while. Nice addition for Linux users. Thanks. As an aside, I can build the LV2, VST2 and Standalone versions and they work perfectly.

VST3 plugins are new in Linux and suffice it to say they are few and far between. Not to mention problematic in Linux. However, since VST3 is next generation I am interested in any that can work in Linux.

I tried to build the VST3 as you suggested commenting out those lines, but both Bitwig and Reaper crashed (Segmentation fault) when trying to load them as GUI enabled plugins :-(

Up to date and to my knowledge the only VST3 plugins that present a GUI are Surge's VST3, which loads and plays well in Reaper but in Bitwig it loads but presents a black screen (the maintainer is hoping to fix that eventually) and Auburn Sounds has success with their VST3 versions of Graillon, Panagement and Couture which load their respective GUI's in both Reaper and Bitwig.

The other problem is VST3 hosts are limited in Linux. Apart from Reaper and Bitwig I think the only other host that can load VST3 plugins is the most recent version of Carla.

I am not a developer, but I use Debian Buster for audio production and build most of the software I use locally so perhaps can help with testing and troubleshooting.

Hi.

Thanks for info about the state of VST 3 on Linux. I once looked in Surge's code, though I couldn't figure out how GUI was working. It was complex.

I'd also hope that there will be more host to properly supports VST 3. I feel current state is not good even on Windows. I mainly use FL Studio, but it has issue on displaying/refreshing GUI. Reaper is better, but it crashed when opening GUI editor provided by VST 3 SDK. Ableton Live doesn't support note ID. Perhaps it's still early days for VST 3, even that it was released in 2008.

Anyway, I pushed fix for Linux GUI to the repositoty. But to build it, you have to patch vst3sdk for now because there are some bugs. I've already made patch and opened issue on vstgui repositoty.

To apply patch, replace vst3sdk/vstgui4/vstgui/lib/platform/linux/cairocontext.cpp with patched cairocontext.cpp in above link.

I tested on reaper v6.03 on Fedora 31.

They all build and display in Reaper (stable) and Bitwig (intermittent). All presets load except for WaveCymbal which appear to be corrupted.

In Bitwig,
Upon first load (double clicking on the VST3)
WaveCymbal, SyncSawSynth, SevenDelay, FDNCymbal, EnvelopeSine all display the GUI

but TrapezpoidSynth and IterativeSinCluster have the same Black Screen as Surge VST3 has

however if I close and reopen them they generally return a Black Screen

I set up a Content Location folder and all plugins find their respective presets.

Bitwig classifies FDNCymbal TrapezpoidSynth WaveCymbal as Audio FX
and EnvelopeSine SyncSawSynth and IterativeSinCluster as Instruments

highlighting any of the plugins will display their presets in the Browser, whenever these presets are clicked they will open the respective plugin with the preset loaded and show its GUI, this happens almost 100% of the time and is the most stable way to open the plugin to get its GUI to load, so oddly if the plugin is open by double clicking it, it will likely have a black screen but if it is opened by double clicking a preset it displays the GUI.

It works for all except WaveCymbal because it appears those presets are corrupted or misconfigured, as it returns an error that it could not load the preset. Reaper does not return an error but any preset will not change WaveCymbal's settings.

It looks like for the time being the only hosts capable of loading VST3 are Reaper and Bitwig.

Carla has had a recent update but is still not VST3 ready in Linux. As per the latest news on the KXstudio web site...

Carla supports VST3 under macOS and Windows, and AU under macOS.

Worth noting is that JUCE does not support VST3 under Linux at this point, so neither does Carla even if you build it yourself with JUCE enabled.

here is a screen capture/video to give you an clearer picture, it seems they respond better when choosing a preset from a plugin that is not already loaded

uhhyou.01-2020-01-19_23.44.21.tar.gz

Update:

Was able to create a preset in Reaper that WaveCymbal was able to recognize and load from Bitwig.
Bitiwg does not locate SevenDelay's presets created in Reaper though.

There seems to be 3 different issues.

1. WaveCymbal Presets

I confirmed it's not working. I'll work on it.

2. Plugin Category

FDNCymbal and WaveCymbal are defined as kFxInstrument in PluginName/source/plugfactory.cpp. So it should appear in both FX and Instrument (or Synth) section. Probably Bitwig doesn't implement this feature. To add this, I confirmed that Reaper and FL Studio only recognize FDNCymbal and WaveCymbal as Synth, not FX. I'll send bug reports to these 3 hosts.

TrapezoidSynth is incorrectly set as kFxInstrument. I changed category to kInstrumentSynth so it should be fixed now.

3. Plugin GUI Blackout on Bitwig

I tested VST 3 SDK example plugins with GUI on Bitwig.

  • AGain : Blackout
  • Note Expression Synth with UI : Blackout
  • VST3 Host Checker : Working

Screenshot:

Screenshot_2020-01-20_20-51-22

So blackouts are not only affected to my plugins, but also plugins that use vstgui on Linux. I'll file a bug report for this one.

In code, only difference for Linux and other OS is this:

// PlugEditor inherits: public VSTGUIEditor, public IControlListener, public IMouseObserver
bool PlugEditor::open(void *parent, const PlatformType &platformType)
{
  if (frame) return false;

  setIdleRate(1000 / 60);

  frame = new CFrame(
    CRect(viewRect.left, viewRect.top, viewRect.right, viewRect.bottom), this);
  if (frame == nullptr) return false;
  frame->setBackgroundColor(colorWhite);
  frame->registerMouseObserver(this);

  IPlatformFrameConfig *config = nullptr;
#if LINUX
  X11::FrameConfig x11config;
  // RunLoop is defined in `vst3sdk/vstgui4/vstgui/plugin-bindings/vst3editor.cpp`.
  x11config.runLoop = VSTGUI::owned(new RunLoop(plugFrame));
  config = &x11config;
#endif
  frame->open(parent, platformType, config);

  // ...
}

WaveCymbal presets are fixed.

just an FYI,

JUCE6 has now fixed the VST3 run time problem and it is now possible to build VST3 for Linux using JUCE

Bitwig has also applied fixes in their current v3.2 beta 5 release for VST3. Looks like all your VST3 instruments now load the GUI without issue in Bitwig (v3.2 beta 5), will have to wait for the 3.2 release unless you want to test the beta release

Carla has also added VST3 support and they load well in there

Reaper was always good

Thanks for the information.

That's nice to hear Bitwig fixed the bug. I'll try when it hits version 3.3 3.2.


I misunderstood that next version of Bitwig would be 3.3.

I tested some of my plugins on Bitwig 3.2 on Ubuntu 18.04, and it looks like working without blackout. @tank-trax Could you confirm it?

yes they are working now without black screen, Bitwig and the maintainer of Surge Synth worked together to find a solution for VST3 plugins :-)

Thanks for confirmation.

I close this issue. If the black screen problem is back, feel free to reopen this issue.