diff options
author | Robin Gareus <robin@gareus.org> | 2016-11-15 17:07:55 +0100 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2016-11-15 17:10:13 +0100 |
commit | a15a3162360f67ba7a40175117c0fe99bc93f2a8 (patch) | |
tree | f97edc0dce3433f6bb02ffd734ce235b7c0333b1 /gtk2_ardour/mac_vst_plugin_ui.mm | |
parent | cf1651e6d7b615cba28025a5952afcc99946c18f (diff) |
consolidate VST UI code
Diffstat (limited to 'gtk2_ardour/mac_vst_plugin_ui.mm')
-rw-r--r-- | gtk2_ardour/mac_vst_plugin_ui.mm | 23 |
1 files changed, 1 insertions, 22 deletions
diff --git a/gtk2_ardour/mac_vst_plugin_ui.mm b/gtk2_ardour/mac_vst_plugin_ui.mm index a1803b6e60..5a20af8036 100644 --- a/gtk2_ardour/mac_vst_plugin_ui.mm +++ b/gtk2_ardour/mac_vst_plugin_ui.mm @@ -156,26 +156,5 @@ MacVSTPluginUI::idle () void MacVSTPluginUI::set_program () { - VSTState* vstfx = _vst->state(); - - if (vstfx->want_program != -1) { - if (vstfx->vst_version >= 2) { - vstfx->plugin->dispatcher (vstfx->plugin, 67 /* effBeginSetProgram */, 0, 0, NULL, 0); - } - - vstfx->plugin->dispatcher (vstfx->plugin, effSetProgram, 0, vstfx->want_program, NULL, 0); - - if (vstfx->vst_version >= 2) { - vstfx->plugin->dispatcher (vstfx->plugin, 68 /* effEndSetProgram */, 0, 0, NULL, 0); - } - - vstfx->want_program = -1; - } - - if (vstfx->want_chunk == 1) { - pthread_mutex_lock (&vstfx->state_lock); - vstfx->plugin->dispatcher (vstfx->plugin, 24 /* effSetChunk */, 1, vstfx->wanted_chunk_size, vstfx->wanted_chunk, 0); - vstfx->want_chunk = 0; - pthread_mutex_unlock (&vstfx->state_lock); - } + vststate_maybe_set_program (_vst->state()); } |