Commit Graph

1980 Commits

Author SHA1 Message Date
Robbert van der Helm dec19dc12a 💥 Reimplement VST3 audio processing
In the same way as 50c25c1cf0 did it for
VST2 plugins. Input and output audio data is now stored in a shared
memory buffer instead of being sent over the sockets. This reduces the
bridging overhead to a minimum since copying data was the most expensive
operation we were doing and we now only need to copy the entire buffer
once per processing cycle.
2021-06-11 13:59:37 +02:00
Robbert van der Helm a7d8063db4 Add getters for channel counts in audio buffers 2021-06-11 13:38:29 +02:00
Robbert van der Helm 340d376564 Add constant overloads for audio buffer pointers 2021-06-11 12:58:46 +02:00
Robbert van der Helm 964c150158 Use the in new place optional extension 2021-06-10 23:44:47 +02:00
Robbert van der Helm f5214b7686 Add an in place std::optional bitsery extension
To avoid unnecessarily recreating the object during deserialization.
This has also been upstreamed to
https://github.com/fraillt/bitsery/pull/78.
2021-06-10 23:43:45 +02:00
Robbert van der Helm 14e3ed2cd3 Add shared audio buffers config to IAudioProcessor::setupProcessing() 2021-06-10 21:37:42 +02:00
Robbert van der Helm 50c25c1cf0 💥 Reimplement VST2 audio processing
We now use shared memory to store the input and output audio buffers.
This means that we have to copy less data every processing cycle, since
a single copy to and a single copy from the shared memory object
suffices now. This should reduce the DSP load for VST2
plugins (especially when used in a plugin group) marginally to
significantly depending on the plugins used and the system
configuration.
2021-06-10 17:31:32 +02:00
Robbert van der Helm 80fa010af5 Prevent unnecessary copies in VST2 event handling 2021-06-10 17:31:32 +02:00
Robbert van der Helm 1bc804965c Clean up lambdas in VST2 variant visitors 2021-06-10 16:53:55 +02:00
Robbert van der Helm f99781c1b2 Make getting channel pointers noexcept
There should be no bounds checks in release mode anyways, and we'll
trust ourselves that this will be a simple lookup.
2021-06-10 16:09:55 +02:00
Robbert van der Helm 0370c64f99 Allow resizing shared memory buffers 2021-06-10 16:09:55 +02:00
Robbert van der Helm 23d99411c8 Define the Ack message in serialization/common.h
We're going to need this for VST2 audio processing.
2021-06-10 16:09:55 +02:00
Robbert van der Helm 503d8248c2 Refactor VST2 serialization primitives
Bundle all serialization function with the structs whenever possible to
simplify the serialization function, and add `Foo::Response` types so we
can make the `passthrough_event()` function slightly more type safe.
2021-06-10 13:13:01 +02:00
Robbert van der Helm cacfc0b379 Fix serializing VST2 speaker arrangements 2021-06-10 13:05:47 +02:00
Robbert van der Helm 53d59f74d1 Reduce the VST2 events small vector capacities
Every DAW will just send all events in one go (and I think that's the
only way you should do it, but the VST2 spec is a bit leaky so who
knows). It wouldn't make much sense to preallocate more capacity,
because when DAWs do send all of those events individually they might
end up sending more than four of these anyways.
2021-06-10 12:43:54 +02:00
Robbert van der Helm 5a38a2e482 Lock mapped shared memory for audio buffers 2021-06-10 01:35:43 +02:00
Robbert van der Helm a3aaeaa9a9 Mention that busses and channels are zero indexed 2021-06-09 20:47:52 +02:00
Robbert van der Helm 2210cb4fc3 Implement move semantics for shared audio buffer 2021-06-09 20:35:47 +02:00
Robbert van der Helm 9d11b501cd Add a shared memory based audio buffer
We'll be using this to reduce the amount of copying we have to do during
audio processing.
2021-06-09 20:06:57 +02:00
Robbert van der Helm e36a7e7e72 Add the effSetProcessPrecision opcode 2021-06-09 18:41:34 +02:00
Robbert van der Helm 087d5a6f87 Remind ourselves that we somehow survived 2020 2021-06-09 16:48:27 +02:00
Robbert van der Helm 53e4fa369f Bump to version 3.3.1 3.3.1 2021-06-09 16:36:02 +02:00
Robbert van der Helm 19e78e22b5 Reword changelog 2021-06-09 16:36:02 +02:00
Robbert van der Helm 70d18edce2 Fix version strings when building from tarball
When that tarball has been extracted in an (unrelated) git repository.
2021-06-09 16:19:01 +02:00
Robbert van der Helm 8f655f71a6 Amend description of the disable_pipes option
This feature was part of yabridge 3.3.0, so it's no longer a master
branch only feature.
2021-06-09 15:58:48 +02:00
Robbert van der Helm 2b7839059c Update the tested DAWs list 2021-06-09 15:30:32 +02:00
Robbert van der Helm e421048925 Correctly configure clang-tidy for src/wine-host 2021-06-09 13:42:45 +02:00
Robbert van der Helm d1badcb589 Prevent exceptions in IndividualHost::running
Apparently this might otherwise throw in some situations.
2021-06-09 13:09:57 +02:00
Robbert van der Helm c97595a391 Mark Vst{2,3}Sockets as final
Since we're calling a virtual method during the destructor.
2021-06-09 13:04:51 +02:00
Robbert van der Helm 6fd31168d8 Reword changelog 2021-06-09 12:41:07 +02:00
Robbert van der Helm 7c9cd7b9e5 Fix uninitialized timed caches
This could prevent resizeable plugins from being resizeable in Ardour if
the initialized timestamp just happened to be greater than the current
time, since the returned result would then likely be some invalid value.
2021-06-09 12:31:03 +02:00
Robbert van der Helm fb1eefa880 Reorder changelog 2021-06-09 12:21:13 +02:00
Robbert van der Helm 65c05aac88 Indicate cached IPlugView::canResize() calls
We apparently forgot to pass the flag here after implementing it in the
log function.
2021-06-09 12:07:29 +02:00
Robbert van der Helm da5f6e9e7d Always initialize Microsoft COM unconditionally 2021-06-07 22:24:48 +02:00
Robbert van der Helm a7496fae77 Add thread names 2021-06-06 23:45:47 +02:00
Robbert van der Helm fe7f6eff96 Make the last commit appear a little less drastic 2021-06-05 11:41:22 +02:00
Robbert van der Helm 974951e966 Translate mouse coordinates from Wine window
Instead of the parent Window. Tracktion Waveform does some weird things
with its VST2 editor embedding, so with the old approach this would
cause mouse clicks to be offset 27 pixels vertically and one pixel
horizontally.
2021-06-05 11:32:24 +02:00
Robbert van der Helm 9254d73c9d Add Waveform to the tested DAWs list 2021-06-05 11:30:54 +02:00
Robbert van der Helm dfeb28a09e Mention rtirq in the performance tuning section
Depending on your system threadirqs on their own may not be enough, and
you actually need to make sure that your sound card's interrupt get
higher priority than other devices triggering interrupts.
2021-06-04 12:45:43 +02:00
Robbert van der Helm 7228d49507 Bump to version 3.3.0 3.3.0 2021-06-03 17:35:45 +02:00
Robbert van der Helm e8a0a66a53 Reword the changelog, again 2021-06-03 17:35:45 +02:00
Robbert van der Helm 2be6388830 Reword the changelog 2021-06-03 14:29:28 +02:00
Robbert van der Helm 3baccf885d Remove old todo 2021-06-01 18:18:44 +02:00
Robbert van der Helm 712ef41a7f Make realtime scheduling less aggressive
On the Wine side. Instead of always having it enabled and disabling it
when it could potentially hurt (i.e. when handling GUI related things),
we'll now only enable it when it's potentially beneficial. This way we
don't have to constantly switch scheduling policies on the GUI thread.
2021-06-01 16:21:38 +02:00
Robbert van der Helm 5f4ffed90b Prevent allocations in Vst3Logger::log_query_interface
String constants will be converted to `std::string` because it's not
constexpr yet, and that will allocate for longer strings. Since this
function only prints something when `YABRIDGE_DEBUG_LEVEL` is set to 2
or higher that seems like a waste.
2021-05-31 18:07:19 +02:00
Robbert van der Helm 2bf1c4c5eb Use C++20 [[unlikely]] instead of BOOST_UNLIKELY 2021-05-31 17:50:02 +02:00
Robbert van der Helm 6a047497bc Only print query interface messages on log level 2 2021-05-31 17:44:43 +02:00
Robbert van der Helm 511aa14700 [yabridgectl] Fix reporting of new VST3 plugins
When yabridgectl sets up both a VST3 bundle containing both a 32-bit and
a 64-bit plugin. The libyabridge.so file already existed, so the
reported number was always off.
2021-05-31 17:05:34 +02:00
Robbert van der Helm 50fba36526 Add instructions for unhide mount on older distros
Apparently you can tell udisks2 which options are safe to be used by a
user. More recent versions of udisks2 include the udf unhide option by
default. This closes #102.
2021-05-31 15:16:34 +02:00
Robbert van der Helm 70467a31dc Fix compilation under GCC 11 2021-05-30 17:54:45 +02:00