As it turns out there are only two or three functions where we can do
this. It also breaks logging, and this function will probably only be
called once anyways. More consistency is always better.
This is quite a huge refactor, but note everything is consistent (and
we're going to need one or two more of these `Vst3*Proxy` objects).
Right now nothing extends `IHostApplication`, but this way it will be
trivial to add support for more host context interfaces.
Adding versions to our implementations doesn't work when the versions
and extensions start becoming non-numerical. This is what happened with
`IComponentHandler`.
Since these functions are exactly the same, and for whatever reason they
didn't just add them to the `IPluginBase` both `IComponent` and
`IEditController`. inherit from
We can now use implement all VST3 plugin interfaces through this class,
check whether the object from the plugin also supports these classes,
and then conditionally allow casting to the supported classes. This
should give us a one-to-one proxy of the original object.
We're also going to need this for `IEditController`. Separating all of
these classes will also keep everything much more maintainable with all
of these associated structs.
With this the entire `IAudioProcessor` interface has been implemented
and in theory it should now be possible to process audio and events.
Logging for these requests still has to be implemented separately.
With this the basic IComponent interface is fully implemented. Next will
be `IAudioProcessor` and `IConnectionPoint` as additions to IComponent.
We'll use the same `known_iids` mechanism as used in the plugin factory.
Directly serializing and deserializing into objects was and more
boilerplate heavy (since we now need two implementations even though we
only use one), and also much less flexible because we can't wrap
payloads in structs or provide optional values that way.
This is less likely to clash with names used by interfaces and it's a
bit clearer what's going on (since they are basically proxies for
constructors and destructors).