From b90baf217632b203e66c296217eb357637a18430 Mon Sep 17 00:00:00 2001 From: "Julien \"_FrnchFrgg_\" RIVAUD" Date: Wed, 3 Aug 2016 12:14:12 +0200 Subject: [PATCH] Move MIDI filters imprecise handling from 2nd pass to 1st This doesn't change the policy since configurations are given an additional 1000 penalty if audio_in != possible_in, and will thus be trumped by any "precise" configuration (unless the latter has 1000 excess or missing outputs which should be less than likely). --- libs/ardour/luaproc.cc | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/libs/ardour/luaproc.cc b/libs/ardour/luaproc.cc index 35f43b5dc1..9b9b7fa46d 100644 --- a/libs/ardour/luaproc.cc +++ b/libs/ardour/luaproc.cc @@ -453,6 +453,9 @@ LuaProc::can_support_io_configuration (const ChanCount& in, ChanCount& out, Chan if (audio_in == 0) { FOUNDCFG(possible_out); break; + } else if (imprecise) { + // TODO hide audio input from plugin + FOUNDCFG_IMPRECISE (possible_in, possible_out); } } continue; @@ -533,12 +536,6 @@ LuaProc::can_support_io_configuration (const ChanCount& in, ChanCount& out, Chan int possible_out = io["audio_out"].isNumber() ? io["audio_out"] : -1; int possible_midiin = _has_midi_input ? 1 : 0; - if (possible_out == 0 && possible_in == 0 && _has_midi_output) { - assert (audio_in > 0); // no input is handled above - // TODO hide audio input from plugin - FOUNDCFG_IMPRECISE (possible_in, possible_out); - continue; - } assert (possible_in > 0); // all other cases will have been matched above -- 2.30.2