From e4177f2856016d7b64f46ebf09d18776d6420c50 Mon Sep 17 00:00:00 2001 From: Robbert van der Helm Date: Thu, 29 Apr 2021 14:29:15 +0200 Subject: [PATCH] Avoid IAudioProcessor::isActive() on GUI thread I haven't seen this cause any issues this way, and I could imagine that this could cause some hangs when initializing a second instance of a plugin while you're interacting with the GUI of the first instance. --- src/wine-host/bridges/vst3.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/wine-host/bridges/vst3.cpp b/src/wine-host/bridges/vst3.cpp index 280c6140..2d807488 100644 --- a/src/wine-host/bridges/vst3.cpp +++ b/src/wine-host/bridges/vst3.cpp @@ -1303,10 +1303,7 @@ size_t Vst3Bridge::register_object_instance( // handled from the same thread to prevent // deadlocks caused by mutually recursive function // calls. - // TODO: Check if this causes any issues when activating - // plugins while simultaneously resizing another - // instance of the same plugin - return do_mutual_recursion_on_gui_thread( + return do_mutual_recursion_on_off_thread( [&]() { return object_instances[request.instance_id] .component->setActive(request.state);