13
0

Fix plugin analysis for some VST and AU Plugins.

set_block_size() implies plugin deactivate(), activate() calls
to re-initialize AU and VST plugins. So plugins will reset the
internal state and not immediately respond correctly.
Some plugins zero the output or ramp up internally, leading the analyzer
to show invalid or random/uncorrelated information.

This avoid periodic calls to de/activate()
This commit is contained in:
Robin Gareus 2018-04-13 23:19:13 +02:00
parent 4983eb565d
commit cc5e758a08

View File

@ -164,6 +164,7 @@ PluginEqGui::start_listening ()
_plugin->activate();
set_buffer_size(4096, 16384);
_plugin->set_block_size (_buffer_size);
// Connect the realtime signal collection callback
_plugin_insert->AnalysisDataGathered.connect (analysis_connection, invalidator (*this), boost::bind (&PluginEqGui::signal_collect_callback, this, _1, _2), gui_context());
}
@ -364,7 +365,6 @@ PluginEqGui::run_impulse_analysis()
// map output buffers after input buffers (no inplace for VST)
out_map.offset_to (DataType::AUDIO, inputs);
_plugin->set_block_size (_buffer_size);
_plugin->connect_and_run(_bufferset, 0, _buffer_size, 1.0, in_map, out_map, _buffer_size, 0);
samplecnt_t f = _plugin->signal_latency ();
// Adding user_latency() could be interesting