From c1a2c6b1fabca7b3a6af8339038f40c700ff1e9b Mon Sep 17 00:00:00 2001 From: Mike Choi Date: Fri, 18 Jan 2013 09:57:51 +0100 Subject: [PATCH] VST effects: secure master channel freezing Master channel keeps freezing, when VST effects are placed directly into Master channels FxChain, on slower computers. Provided solution prolongs VST initialisation phase, by waiting on two extra messages, which usually follows initialisation and are possibly not yet implemented well. IdSampleRateInformation, IdBufferSizeInformation This seems to prevent Master channel freezes e.g. on VST effects like Tiny-Q. Signed-off-by: Tobias Doerffel --- plugins/vst_base/RemoteVstPlugin.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/plugins/vst_base/RemoteVstPlugin.cpp b/plugins/vst_base/RemoteVstPlugin.cpp index 2344d1060..1231cb1c4 100644 --- a/plugins/vst_base/RemoteVstPlugin.cpp +++ b/plugins/vst_base/RemoteVstPlugin.cpp @@ -335,7 +335,12 @@ RemoteVstPlugin::RemoteVstPlugin( key_t _shm_in, key_t _shm_out ) : { message m = receiveMessage(); processMessage( m ); - if( m.id == IdVstLoadPlugin || m.id == IdQuit ) + //if( m.id == IdVstLoadPlugin || m.id == IdQuit ) + + // IdBufferSizeInformation is sent right after plugin load + // otherwise causes deadlocks to FxMixer/EffectChain + + if( m.id == IdBufferSizeInformation || m.id == IdQuit ) { break; }