diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2008-09-10 15:03:30 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2008-09-10 15:03:30 +0000 |
commit | 68e943265edf04e63a8e8b8f62bab20f99d9c637 (patch) | |
tree | ff8941a59662fc0c4622944b65f7b2d5e3bdd0c3 /libs/ardour/send.cc | |
parent | e4372df05b7d74a6b80dbbf4b6c00cc2b31c4723 (diff) |
merge from 2.0-ongoing @ 3581
git-svn-id: svn://localhost/ardour2/branches/3.0@3711 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/send.cc')
-rw-r--r-- | libs/ardour/send.cc | 41 |
1 files changed, 21 insertions, 20 deletions
diff --git a/libs/ardour/send.cc b/libs/ardour/send.cc index 736a443c72..a80e99a1ee 100644 --- a/libs/ardour/send.cc +++ b/libs/ardour/send.cc @@ -156,13 +156,13 @@ Send::set_metering (bool yn) } bool -Send::can_support_input_configuration (ChanCount in) const +Send::can_support_io_configuration (const ChanCount& in, ChanCount& out_is_ignored) const { if (_io->input_maximum() == ChanCount::INFINITE && _io->output_maximum() == ChanCount::INFINITE) { /* not configured yet */ - return true; /* we can support anything the first time we're asked */ + return 1; /* we can support anything the first time we're asked */ } else { @@ -171,42 +171,35 @@ Send::can_support_input_configuration (ChanCount in) const */ if (_io->output_maximum() == in) { - - return true; + return 1; } } - return false; -} - -ChanCount -Send::output_for_input_configuration (ChanCount in) const -{ - // from the internal (Insert) perspective a Send does not modify its input whatsoever - return in; + return -1; } bool Send::configure_io (ChanCount in, ChanCount out) { /* we're transparent no matter what. fight the power. */ - if (out != in) + + if (out != in) { return false; + } _io->set_output_maximum (in); _io->set_output_minimum (in); _io->set_input_maximum (ChanCount::ZERO); _io->set_input_minimum (ChanCount::ZERO); - bool success = _io->ensure_io (ChanCount::ZERO, in, false, this) == 0; - - if (success) { - Processor::configure_io(in, out); - _io->reset_panner(); - return true; - } else { + if (_io->ensure_io (ChanCount::ZERO, in, false, this) != 0) { return false; } + + Processor::configure_io(in, out); + _io->reset_panner(); + + return true; } ChanCount @@ -226,3 +219,11 @@ Send::input_streams() const } +void +Send::expect_inputs (const ChanCount& expected) +{ + if (expected != expected_inputs) { + expected_inputs = expected; + _io->reset_panner (); + } +} |