X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=libs%2Fardour%2Finternal_return.cc;h=28089feef466f09eae4df7257ac9a989045bb921;hb=379ad3357df6cba267b7005aac572d6821487269;hp=fc5963603b5ac572d7d9313b3211b0b2c07bacc4;hpb=bfd50cdeb0416b106a7813177148dffb1af6db8e;p=ardour.git diff --git a/libs/ardour/internal_return.cc b/libs/ardour/internal_return.cc index fc5963603b..28089feef4 100644 --- a/libs/ardour/internal_return.cc +++ b/libs/ardour/internal_return.cc @@ -20,6 +20,7 @@ #include "ardour/internal_return.h" #include "ardour/internal_send.h" +#include "ardour/route.h" using namespace std; using namespace ARDOUR; @@ -31,17 +32,17 @@ InternalReturn::InternalReturn (Session& s) } void -InternalReturn::run (BufferSet& bufs, framepos_t /*start_frame*/, framepos_t /*end_frame*/, pframes_t nframes, bool) +InternalReturn::run (BufferSet& bufs, framepos_t /*start_frame*/, framepos_t /*end_frame*/, double /*speed*/, pframes_t nframes, bool) { if (!_active && !_pending_active) { return; } Glib::Threads::Mutex::Lock lm (_sends_mutex, Glib::Threads::TRY_LOCK); - + if (lm.locked ()) { for (list::iterator i = _sends.begin(); i != _sends.end(); ++i) { - if ((*i)->active ()) { + if ((*i)->active () && (!(*i)->source_route() || (*i)->source_route()->active())) { bufs.merge_from ((*i)->get_buffers(), nframes); } } @@ -69,7 +70,7 @@ InternalReturn::state (bool full) { XMLNode& node (Return::state (full)); /* override type */ - node.add_property("type", "intreturn"); + node.set_property("type", "intreturn"); return node; }