mirror of
https://github.com/robbert-vdh/yabridge.git
synced 2026-06-17 00:43:56 +02:00
Handle mutual recursion while loading presets
This commit is contained in:
@@ -81,6 +81,8 @@ Versioning](https://semver.org/spec/v2.0.0.html).
|
|||||||
- Fixed the VST3 version of _W. A. Production ImPerfect_ from crashing during
|
- Fixed the VST3 version of _W. A. Production ImPerfect_ from crashing during
|
||||||
audio setup.
|
audio setup.
|
||||||
- Fixed _UVI Plugsound Free_ crashing during initialization.
|
- Fixed _UVI Plugsound Free_ crashing during initialization.
|
||||||
|
- Fixed a rare potential freeze when loading a VST3 plugin preset while the
|
||||||
|
plugin is being resized.
|
||||||
- Because of the new transport information prefetching, the excessive DSP usage
|
- Because of the new transport information prefetching, the excessive DSP usage
|
||||||
in _SWAM Cello_ is now been fixed without requiring any manual compatibility
|
in _SWAM Cello_ is now been fixed without requiring any manual compatibility
|
||||||
options.
|
options.
|
||||||
|
|||||||
@@ -234,20 +234,20 @@ void Vst3Bridge::run() {
|
|||||||
-> Vst3PluginProxy::SetState::Response {
|
-> Vst3PluginProxy::SetState::Response {
|
||||||
// We need to run `getState()` from the main thread, so we might
|
// We need to run `getState()` from the main thread, so we might
|
||||||
// as well do the same thing with `setState()`. See below.
|
// as well do the same thing with `setState()`. See below.
|
||||||
return main_context
|
// NOTE: We also try to handle mutual recursion here, in case
|
||||||
.run_in_context<tresult>([&]() {
|
// this happens during a resize
|
||||||
// This same function is defined in both `IComponent`
|
return do_mutual_recursion_on_gui_thread<tresult>([&]() {
|
||||||
// and `IEditController`, so the host is calling one or
|
// This same function is defined in both `IComponent` and
|
||||||
// the other
|
// `IEditController`, so the host is calling one or the
|
||||||
if (object_instances[request.instance_id].component) {
|
// other
|
||||||
return object_instances[request.instance_id]
|
if (object_instances[request.instance_id].component) {
|
||||||
.component->setState(&request.state);
|
return object_instances[request.instance_id]
|
||||||
} else {
|
.component->setState(&request.state);
|
||||||
return object_instances[request.instance_id]
|
} else {
|
||||||
.edit_controller->setState(&request.state);
|
return object_instances[request.instance_id]
|
||||||
}
|
.edit_controller->setState(&request.state);
|
||||||
})
|
}
|
||||||
.get();
|
});
|
||||||
},
|
},
|
||||||
[&](Vst3PluginProxy::GetState& request)
|
[&](Vst3PluginProxy::GetState& request)
|
||||||
-> Vst3PluginProxy::GetState::Response {
|
-> Vst3PluginProxy::GetState::Response {
|
||||||
|
|||||||
Reference in New Issue
Block a user