I have custom VST Host running a custom VST Plugin inside. And I want to have custom interface between them, but after certain amount of experiments can’t see anything better than named pipes, that is an overkill, I don’t believe it’s the best way. Since I can do anything both with host and plugin.
Plugin is separate DLL/Bundle that I load dynamically:
So far I have found a better solution than named pipes. I export another function from dll/bundle and use it to get last plugin created. Call it after I instantiate plugin. Still not brilliant…
ujam: thank you, I’m looking if we have that in Juce…
If you’re in control of both the host and plugin, why use a host/plugin architecture at all? If you can just build one app with everything integrated and avoid VST altogether, you’ll save yourself an awful lot of hassle with APIs and DLLs.
…for example in ROLI’s NOISE app, the engine is Tracktion and the synths are Equator and FXpansion’s multi-synth. We could have made it run with all these things as VSTs in separate DLLs, but it was way cleaner for us to just link them both as static libs in one big executable and talk to them directly as AudioProcessor objects.
Because there is hardware DSP, application to control hardware, VST version of effect, and Standalone application for that VST plugin. And everything is almost identical, so shares the same code.
Static link to DLL is one of the solutions, but I’d like to load it dynamically, why not? Since we have DLL already, and I have time to investigate.
Thank you everybody,
More ideas are still welcome, if you have time and will )
Well, because of problems like the one that made you come and post this question!
It’s very similar to our situation with NOISE - obviously for something like Equator it needs to be a plugin and standalone too, but statically linking just the core functionality into a DAW makes it easy to do custom integration, improves the performance, means we don’t have to deploy a DLL, avoids having to scan to find it, etc.
I wish those were biggest problems in my life )) And I don’t mind talking with smart gentlemen in this forum, moreover I like it )
Of course you are right that static linking is simpler and good for small plugins.
So far I acquire object pointer from dll/bundle, it’s not hard at all and works fine. Everybody who wants to do the same (at least for huge plugins it’s better) - mind that dll functions you call should be virtual and don’t delete dll side allocated stuff in host. But these are general dll related considerations…
Jules, thank you for Juce. Just using opportunity to say so )