Robbert van der Helm
79c6f02d91
Request and deserialize plugin factory from plugin
2020-12-07 18:28:16 +01:00
Robbert van der Helm
d5374e4540
💥 Rework Vst3MessageHandler
...
- Now allows direct deserialization into existing objects. This will be
necessary for our VST3 implementations since the interface instances
we'll deserialize into will not be trivially constructable because
they have to be able to do callbacks.
- `ControlResponse` and `CallbackResponse` were dropped. These response
enums are not necessary because of the `T::Response` associated type
and returning the types directly makes the direct deserialization
possible.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
049eb257c5
Make YaPluginFactory abstract
...
And add separate implementations for the native plugin and the Wine
plugin host. This way we can easily allow the native host to do
callbacks without having to manage a load of lambdas.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
930ebbf7d1
Add more todos for VST3 handling
2020-12-07 18:28:16 +01:00
Robbert van der Helm
426231a22b
Avoid potential UB in loggers using composition
...
This cast would work fine, but any other fields added to those loggers
would be left uninitialized.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
c1e7f53cd0
💥 Major refactor of initialization plumbing
...
To account for the differences in VST2 plugins and VST3 modules we had
to wrap most of our old functions from `src/plugin/utils.h` in a new
`PluginInfo` struct that gathers all of this information while taking
into account the differences between VST2 and VST3 plugins.
With this change things are also a lot more organized. We can just query
the plugin information we need rather than having to store things
separately or having to recalculate things. This also moved the
responsibility of all the weird `WINEPREFIX` behaviour to a single place
instead of having it spread around `utils.pp`, the initialisation
message, and `host-procoess.cpp`.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
0819e9fda9
Request/send config for VST3 plugins
...
Using the new Vst3MessageHandler.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
2e9b100090
Add handlers for control messages and callbacks
2020-12-07 18:28:16 +01:00
Robbert van der Helm
b9e63ea335
Move the host guard handler to PluginBridge
2020-12-07 18:28:16 +01:00
Robbert van der Helm
c2d2ac8fbf
Inherit Vst3PluginBridge init from PluginBridge
2020-12-07 18:28:16 +01:00
Robbert van der Helm
6b9ae78b27
Factor out all plumbing in Vst2PluginBridge
...
So we can reuse it in Vst3PluginBridge later.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
f845763af0
Print the plugin type during initialisation
2020-12-07 18:28:16 +01:00
Robbert van der Helm
c57fd67aa8
Don't store the Wine version as a field
...
It's only needed for the initialisation message, and it doesn't throw so
doing this later shouldn't make a difference.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
3c72ab31f8
Shut up clang/ccls
2020-12-07 18:28:16 +01:00
Robbert van der Helm
ff2807c939
Add all the boilerplate for the Vst3PluginBridge
...
And now that I also have an idea of what the communication model will
look like, this can server as a base for instantiating plugins.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
0b462c034e
Allow loading VST3 modules
...
Doesn't actually work yet or do anything, but it compiles and it runs.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
a9b7a6a835
List VST3 support in the initialization message
2020-12-07 18:28:16 +01:00
Robbert van der Helm
969ad75da5
Add some more VST3 implementation considerations
2020-12-07 18:28:16 +01:00
Robbert van der Helm
2060606864
Add a list of things to watch out for with VST3
2020-12-07 18:28:16 +01:00
Robbert van der Helm
f9a1bcd7bd
Split VST2 specific functionality into Vst2Logger
2020-12-07 18:28:16 +01:00
Robbert van der Helm
2230b5099f
Move logger to common/logging/common.h
2020-12-07 18:28:16 +01:00
Robbert van der Helm
278cd2e710
Spawn all hosts directly using HostRequest
...
This way we can set the plugin type inside of the `Vst*PluginBridge`
instance.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
e21d3e020f
Rename GroupRequest to HostRequest
...
We'll also use this to encode information in when launching
`yabridge-host.exe` for individually hosted plugins.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
1c5a9423d2
Print the plugin type on initialization
2020-12-07 18:28:16 +01:00
Robbert van der Helm
f9bb3822de
Pass plugin type when calling the host application
2020-12-07 18:28:16 +01:00
Robbert van der Helm
47baef3107
Rename architecture related functions and structs
2020-12-07 18:28:16 +01:00
Robbert van der Helm
7fc7a51a46
Move PluginArchitecture to common
...
Along with the accompanying function to parse a PE32 file. We're going
to have to define some common tags for different plugin types.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
fa719c286d
Create base class for sockets and derive from that
...
Now the host launching procedure can be agnostic of the socket
implementation.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
5b2221b251
Add a (nonfunctional) VST3 entry point
2020-12-07 18:28:16 +01:00
Robbert van der Helm
bb85d99657
Rename 'Sockets' to 'Vst2Sockets'
2020-12-07 18:28:16 +01:00
Robbert van der Helm
2fbd14908a
Split communication/vst2.h into common and VST2
...
So we can reuse the generic bits for our VST3 implementation.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
46bc0301af
Move communication.h to communication/vst2.h
2020-12-07 18:28:16 +01:00
Robbert van der Helm
9ece1b916e
Rename plugin.cpp to vst2-plugin.cpp
2020-12-07 18:28:16 +01:00
Robbert van der Helm
4291083a46
Rename PluginBridge to Vst2PluginBridge
2020-12-07 18:28:16 +01:00
Robbert van der Helm
6195caf53e
Move src/plugin-bridge to src/bridges/vst2
2020-12-07 18:28:16 +01:00
Robbert van der Helm
9d40e04a62
Update all references to libyabridge.so
2020-12-07 18:28:16 +01:00
Robbert van der Helm
84d00b568b
Add a more distinct wrapper around chunk data
2020-12-07 02:43:23 +01:00
Robbert van der Helm
7f7da50282
Log processing cycles on verbosity level 2
2020-12-07 02:08:03 +01:00
Robbert van der Helm
23d5567e72
Add a time info caching compatibility option #62
...
This is needed to get good performance out of SWAM Cello until this
issue is fixed by the plugin.
2020-11-30 14:49:02 +01:00
Robbert van der Helm
21b0f70eda
Rename get_modified_search_path() for clarity
2020-11-20 15:39:29 +01:00
Robbert van der Helm
c69037b649
Always search for host in ~/.local/share/yabridge
2020-11-20 14:24:42 +01:00
Robbert van der Helm
abb2206970
Fix typos in the word 'Boost'
...
Apparently I type very quickly.
2020-11-20 01:15:51 +01:00
Robbert van der Helm
b93f0ddb8b
Don't depend on the parallel STL
...
We were not linking with TBB, and it's a bit of a waste to require it
just for this one unused function.
2020-11-13 13:42:06 +01:00
Robbert van der Helm
7931f38066
Remove the deprecated use-* compilation options
2020-11-08 12:36:47 +01:00
Robbert van der Helm
5486d91201
Fix style
2020-11-07 23:17:00 +01:00
Robbert van der Helm
acdbcaca6a
Fix plugin host fallover behaviour
...
GroupHost::running() would sometimes cause plugins to get terminated
prematurely when connecting to another plugin's group host process since
the plugin's own group host process has exited.
2020-11-07 23:11:49 +01:00
Robbert van der Helm
a0c0a86e2c
Drop the separate effProcessEvents socket
...
Now that event handling is fully concurrent and thus no longer gets
blocked by the Win32 message loop.
2020-11-07 20:54:33 +01:00
Robbert van der Helm
42032c5c2d
Fix the old accumulative process() function
2020-11-07 18:17:21 +01:00
Robbert van der Helm
1c7e866609
No longer return a lambda in passthrough_event()
...
Now that it's no longer used directly this is no longer needed, and it's
much clearer without the lambda.
2020-11-06 17:17:36 +01:00
Robbert van der Helm
ba6381e3ae
Rename EventHandler::{send,receive} to *_event(s?)
...
Since it does something way more involved than
`SocketHandler::{send,receive_multi}`, and that makes it a bit confusing
if you don't already know about that (and even if you do).
2020-11-01 12:01:50 +01:00