diff options
author | Julien "_FrnchFrgg_" RIVAUD <frnchfrgg@free.fr> | 2016-08-02 18:20:42 +0200 |
---|---|---|
committer | Julien "_FrnchFrgg_" RIVAUD <frnchfrgg@free.fr> | 2016-08-06 19:38:09 +0200 |
commit | 19b82b8a8301e80d98d86cc96fa53214f55689db (patch) | |
tree | dd6f29367a4052d3ab74262a6e7bd592ef46eca0 /libs/ardour/luaproc.cc | |
parent | 8311607e5c2ffa16dde1b65b8e40b2ad77f8d70d (diff) |
Use FOUNDCFG* instead of setting the configuration by hand
Diffstat (limited to 'libs/ardour/luaproc.cc')
-rw-r--r-- | libs/ardour/luaproc.cc | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/libs/ardour/luaproc.cc b/libs/ardour/luaproc.cc index 27de050c31..e9a188c82c 100644 --- a/libs/ardour/luaproc.cc +++ b/libs/ardour/luaproc.cc @@ -440,12 +440,9 @@ LuaProc::can_support_io_configuration (const ChanCount& in, ChanCount& out, Chan // exact match if ((possible_in == audio_in) && (possible_out == preferred_out)) { - _output_configs.insert (preferred_out); - audio_out = preferred_out; /* Set penalty so low that this output configuration * will trump any other one */ - penalty = -1; - found = true; + FOUNDCFG_PENALTY(audio_in, preferred_out, -1); } // "imprecise" matches @@ -453,8 +450,7 @@ LuaProc::can_support_io_configuration (const ChanCount& in, ChanCount& out, Chan if (possible_in == 0) { if (_has_midi_output && audio_in == 0) { // special case midi filters & generators - audio_out = 0; - found = true; + FOUNDCFG(possible_out); break; } } @@ -539,9 +535,7 @@ LuaProc::can_support_io_configuration (const ChanCount& in, ChanCount& out, Chan 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 - imprecise->set (DataType::AUDIO, 0); - audio_out = 0; - found = true; + FOUNDCFG_IMPRECISE (possible_in, possible_out); continue; } |