Why VST??

All your LV2 and LADSPA goodness and more.

Moderators: MattKingUSA, khz

glowrak guy
Established Member
Posts: 2325
Joined: Sat Jun 21, 2014 8:37 pm
Been thanked: 256 times

Re: Why VST??

Post by glowrak guy »

As a non-coder, I'm often amazed by the ingenuity of educated, disciplined,
and creative minds. This certainly ranks in the 8) amazing 8) category to me!
ubuntuuser
Established Member
Posts: 315
Joined: Mon Jan 02, 2017 9:46 am
Has thanked: 1 time
Been thanked: 5 times

Re: Why VST??

Post by ubuntuuser »

I can get just about all of the vst plugins that come standard with AV Linux loaded into Reaper Linux with a UI.

The exceptions are u-he and the lsp plugins.

The u-he plugins seem to have a thread bug that hits at random, and some hosts will cope with it better than others but Reaper and my Wrapper don't.

Sometimes the u-he plugins stay up and sometimes they crash with a thread problem.

The lsp plugins generate a gtk error and I don't know what is causing that.

No thread or display issues with all of the other vst's (I think I've tested about 20 or so).

The SAFE vst plugins are buggy from my experience in other hosts and they are buggy in Reaper and my Wrapper as well.

I think if a vst plugin has any sort of bugs in it then they won't work well with Reaper and my wrapper because the Reaper and my wrapper combo can't handle them whereas other hosts might be able to without crashing.
User avatar
sadko4u
Established Member
Posts: 987
Joined: Mon Sep 28, 2015 9:03 pm
Has thanked: 2 times
Been thanked: 361 times

Re: Why VST??

Post by sadko4u »

ubuntuuser wrote:The lsp plugins generate a gtk error and I don't know what is causing that.
If you have the text of an error, you may submit it to me. I think it's REAPER-relative problem and seems to be fixable.
LSP (Linux Studio Plugins) Developer and Maintainer.
ubuntuuser
Established Member
Posts: 315
Joined: Mon Jan 02, 2017 9:46 am
Has thanked: 1 time
Been thanked: 5 times

Re: Why VST??

Post by ubuntuuser »

sadko4u wrote:
ubuntuuser wrote:The lsp plugins generate a gtk error and I don't know what is causing that.
If you have the text of an error, you may submit it to me. I think it's REAPER-relative problem and seems to be fixable.
I tried a lsp plugin in a vst mini host and in Jost and I get a bad window error in both of them.


./vstminihost /usr/lib/vst/lsp-plugins-vst-compressor-stereo.so
*** This is a 64 Bit Build! ***
VstIntPtr = 8 Bytes, VstInt32 = 4 Bytes, Pointer = 8 Bytes, AEffect = 192 Bytes

HOST> Load library...
HOST> Create effect...
HOST> Init sequence...
HOST> Gathering properties...
Name = Compressor Stereo
Vendor = LSP VST
Product = LSP Kompressor Stereo [VST]

numPrograms = 0
numParams = 29
numInputs = 2
numOutputs = 2


Param 000: bypass [off ] (normalized = 0.000000)
Param 001: g_in [0.00 dB] (normalized = 0.100000)
Param 002: g_out [0.00 dB] (normalized = 0.100000)
Param 003: pause [off ] (normalized = 0.000000)
Param 004: clear [off ] (normalized = 0.000000)
Param 005: sct [Feed-fo ] (normalized = 0.000000)
Param 006: scm [RMS ] (normalized = 1.000000)
Param 007: sla [0.000 ms] (normalized = 0.000000)
Param 008: scl [off ] (normalized = 0.000000)
Param 009: scs [Middle ] (normalized = 0.000000)
Param 010: scr [10.0 ms] (normalized = 0.040000)
Param 011: scp [0.00 dB] (normalized = 0.010000)
Param 012: cm [Downwar ] (normalized = 0.000000)
Param 013: al [-12.00 dB] (normalized = 0.250440)
Param 014: at [20.0 ms] (normalized = 0.010000)
Param 015: rrl [-inf dB] (normalized = 0.000000)
Param 016: rt [100 ms] (normalized = 0.020000)
Param 017: cr [4.00 ] (normalized = 0.030303)
Param 018: kn [-6.00 dB] (normalized = 0.467585)
Param 019: mk [0.00 dB] (normalized = 0.000999)
Param 020: cdr [-inf dB] (normalized = 0.000000)
Param 021: cwt [0.00 dB] (normalized = 0.100000)
Param 022: slv [on ] (normalized = 1.000000)
Param 023: elv [on ] (normalized = 1.000000)
Param 024: grv [on ] (normalized = 1.000000)
Param 025: ilv_l [on ] (normalized = 1.000000)
Param 026: olv_l [on ] (normalized = 1.000000)
Param 027: ilv_r [on ] (normalized = 1.000000)
Param 028: olv_r [on ] (normalized = 1.000000)

Can do receiveVstEvents... don't know
Can do receiveVstMidiEvent... don't know
Can do midiProgramNames... don't know

HOST> Resume effect...
HOST> Process Replacing...
HOST> Process Replacing...
HOST> Process Replacing...
HOST> Process Replacing...
HOST> Process Replacing...
HOST> Suspend effect...
HOST> Get editor rect..
GetRect -> 0, 0
HOST> Open editor...
The program 'vstminihost' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadValue (integer parameter out of range for operation)'.
(Details: serial 12 error_code 2 request_code 12 minor_code 0)
(Note to programmers: normally, X errors are reported asynchronously;
that is, you will receive the error a while after causing it.
To debug your program, run it with the --sync command line
option to change this behavior. You can then get a meaningful
backtrace from your debugger if you break on the gdk_x_error() function.)
User avatar
sadko4u
Established Member
Posts: 987
Joined: Mon Sep 28, 2015 9:03 pm
Has thanked: 2 times
Been thanked: 361 times

Re: Why VST??

Post by sadko4u »

What's the program vstminihost? Where can I get it?
LSP (Linux Studio Plugins) Developer and Maintainer.
Drumfix
Established Member
Posts: 299
Joined: Mon Jan 26, 2009 5:15 pm
Been thanked: 11 times

Re: Why VST??

Post by Drumfix »

request code 12 = XConfigureWindow family of calls (see man XConfigureWindow) .Check the parameters you supply to any of the functions listed there. Most likely you supplied width or height as 0.
User avatar
sadko4u
Established Member
Posts: 987
Joined: Mon Sep 28, 2015 9:03 pm
Has thanked: 2 times
Been thanked: 361 times

Re: Why VST??

Post by sadko4u »

Here's the patch to VST Minihost. Now it's partially working. At least UI is running.
vstminihost.txt
Patch for vstminihost
(4.33 KiB) Downloaded 56 times
LSP (Linux Studio Plugins) Developer and Maintainer.
ubuntuuser
Established Member
Posts: 315
Joined: Mon Jan 02, 2017 9:46 am
Has thanked: 1 time
Been thanked: 5 times

Re: Why VST??

Post by ubuntuuser »

sadko4u wrote:Here's the patch to VST Minihost. Now it's partially working. At least UI is running.
vstminihost.txt
Thanks, it works with vstminihost.

I think I know what my problem is with Reaper and my wrapper and some plugins.

I think it's Reaper doing something to the Gtk Gdk environment or something like that, so it results in crashes on load with the lsp plugins and random crashes with the u-he plugins.
Drumfix
Established Member
Posts: 299
Joined: Mon Jan 26, 2009 5:15 pm
Been thanked: 11 times

Re: Why VST??

Post by Drumfix »

Bravo! After only 8 days you have discovered the unsolvable problem that all linux VST host developers are facing when they want to run plugins using differnt toolkits or versions of a toolkit inside the same process. :mrgreen:
They usually solve this by the brute force method: run the plugin as a whole in its own process.

And now we are back to what the externalUI extension is good for :lol:
ubuntuuser
Established Member
Posts: 315
Joined: Mon Jan 02, 2017 9:46 am
Has thanked: 1 time
Been thanked: 5 times

Re: Why VST??

Post by ubuntuuser »

It's been interesting as there were some other things to try with a vst wrapper and a X11 window.

I've actually managed to get the lsp plugins working in Linux Tracktion using my vst wrapper and it's X11 window.

The lsp plugins don't work in Linux Tracktion, but they work in a vst wrapper with a X11 window.

Vst plugins that have problems with Linux JUCE and Tracktion seem to work with a vst wrapper and a X11 window.


Image
Last edited by ubuntuuser on Sat Jan 28, 2017 11:52 am, edited 3 times in total.
ubuntuuser
Established Member
Posts: 315
Joined: Mon Jan 02, 2017 9:46 am
Has thanked: 1 time
Been thanked: 5 times

Re: Why VST??

Post by ubuntuuser »

A lot of the vst plugins work with the vst wrapper and a X11 window in Linux Reaper but some don't, like the lsp vst's.

It's crashing on libgdk-x11-2.0.so.0 with an error similar to this about critical errors.

Maybe something to do with Reapers libswell.



(java:7456): GLib-GObject-WARNING **: cannot register existing type `GdkDisplayManager'

(java:7456): GLib-CRITICAL **: g_once_init_leave: assertion `result != 0' failed

(java:7456): GLib-GObject-CRITICAL **: g_object_new: assertion `G_TYPE_IS_OBJECT (object_type)' failed

(java:7456): GLib-GObject-WARNING **: invalid (NULL) pointer instance

(java:7456): GLib-GObject-CRITICAL **: g_signal_connect_data: assertion `G_TYPE_CHECK_INSTANCE (instance)' failed

(java:7456): GLib-GObject-WARNING **: invalid (NULL) pointer instance

(java:7456): GLib-GObject-CRITICAL **: g_signal_connect_data: assertion `G_TYPE_CHECK_INSTANCE (instance)' failed

(java:7456): GLib-GObject-WARNING **: cannot register existing type `GdkDisplay'

(java:7456): GLib-CRITICAL **: g_once_init_leave: assertion `result != 0' failed

(java:7456): GLib-GObject-CRITICAL **: g_type_register_static: assertion `parent_type > 0' failed

(java:7456): GLib-CRITICAL **: g_once_init_leave: assertion `result != 0' failed

(java:7456): GLib-GObject-CRITICAL **: g_object_new: assertion `G_TYPE_IS_OBJECT (object_type)' failed
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00007fe97938573f, pid=7456, tid=140641328412416
#
# JRE version: Java(TM) SE Runtime Environment (8.0-b132) (build 1.8.0-b132)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.0-b70 mixed mode linux-amd64 compressed oops)
# Problematic frame:
# C [libgdk-x11-2.0.so.0+0x5173f] gdk_display_open+0x3f
#
User avatar
sadko4u
Established Member
Posts: 987
Joined: Mon Sep 28, 2015 9:03 pm
Has thanked: 2 times
Been thanked: 361 times

Re: Why VST??

Post by sadko4u »

It's probably because REAPER doesn't use effEditOpen callback to open plugin window as other normal hosts do.
The problem with Tracktion like with other JUCE-based hosts is simple: X11 messages don't come to GTK framework. That's sad and currently I don't know good way to fix it. I'm working on pure X11 UI implementation. But it's not quick job.
LSP (Linux Studio Plugins) Developer and Maintainer.
ubuntuuser
Established Member
Posts: 315
Joined: Mon Jan 02, 2017 9:46 am
Has thanked: 1 time
Been thanked: 5 times

Re: Why VST??

Post by ubuntuuser »

sadko4u wrote:It's probably because REAPER doesn't use effEditOpen callback to open plugin window as other normal hosts do.
The problem with Tracktion like with other JUCE-based hosts is simple: X11 messages don't come to GTK framework. That's sad and currently I don't know good way to fix it. I'm working on pure X11 UI implementation. But it's not quick job.
The main reason that I tried the vst wrapper and X11 window was to get vst plugins that can't handle the JUCE bugs working in Linux Tracktion, like the lsp vst plugins and the Drumgizmo vst until they developed a JUCE bug workaround in the latest version.

The Reaper vst wrapper and X11 window works ok with enough plugins to be useful.

If anyone wants to use the lsp (or other vst plugins with JUCE problems) in Traction using my vst wrapper then send me a message and you can have them.

btw the wrapper is empty and doesn't contain any plugins and it just loads the plugin when it's loaded into Tracktion.
User avatar
sadko4u
Established Member
Posts: 987
Joined: Mon Sep 28, 2015 9:03 pm
Has thanked: 2 times
Been thanked: 361 times

Re: Why VST??

Post by sadko4u »

ubuntuuser wrote:It's been interesting as there were some other things to try with a vst wrapper and a X11 window.

I've actually managed to get the lsp plugins working in Linux Tracktion using my vst wrapper and it's X11 window.

The lsp plugins don't work in Linux Tracktion, but they work in a vst wrapper with a X11 window.
Do I right understand that you create your own window instead of using that window that is passed by JUCE to your wrapper?
Could you share the code for better understanding about what your wrapper actually does relative to the UI?
LSP (Linux Studio Plugins) Developer and Maintainer.
ubuntuuser
Established Member
Posts: 315
Joined: Mon Jan 02, 2017 9:46 am
Has thanked: 1 time
Been thanked: 5 times

Re: Why VST??

Post by ubuntuuser »

sadko4u wrote:
ubuntuuser wrote:It's been interesting as there were some other things to try with a vst wrapper and a X11 window.

I've actually managed to get the lsp plugins working in Linux Tracktion using my vst wrapper and it's X11 window.

The lsp plugins don't work in Linux Tracktion, but they work in a vst wrapper with a X11 window.
Do I right understand that you create your own window instead of using that window that is passed by JUCE to your wrapper?
Could you share the code for better understanding about what your wrapper actually does relative to the UI?
It's a vst wrapper with the client on one side and the host on the other side.

Most things just get passed between the client and host with no interference except for the effEditOpen and effEditClose and effEditRect and I'm intercepting them and not passing them between the host (Tracktion) and the client (lsp plugin).

When the effEditOpen happens (usual Tracktion double click on the plugin) then I open a X11 window that's pretty much based on the vstminihost X11 code (and the same for effEditClose).

That's about it.

The client (lsp plugin) only knows about the X11 window, and the host (Tracktion) just generates the effEditOpen and effEditClose and effEditRect that I intercept, and Tracktion puts up a small empty window because I'm not giving Traction any window rect info.

So there are 2 windows, a X11 window with the plugin functioning normally with it and a small blank window put up by Tracktion.

So the lsp plugin functions normally in the X11 window with all controls and displays working and Tracktion just deals with a small blank window that it puts up by default when it can't get window rect info and the blank window doesn't do anything but it can generate a effEditClose when the blank window is closed and that's a trigger to also close the X11 window).

It actually works with no problems at all.
Post Reply