From 400f8bb03dea167c4b1f17b2cc80cf24a0bd4679 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Mon, 29 Sep 2008 09:44:25 +0000 Subject: [PATCH] still call Port::cycle_start() for output ports; remove otification calls from Playlist::add_region() (torben) git-svn-id: svn://localhost/ardour2/branches/3.0@3828 d708f5d6-7413-0410-9779-e7cbd77b26cf --- libs/ardour/audioengine.cc | 16 +++++++++++++++- libs/ardour/playlist.cc | 2 -- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/libs/ardour/audioengine.cc b/libs/ardour/audioengine.cc index 8629a5c0df..d7bbe369fe 100644 --- a/libs/ardour/audioengine.cc +++ b/libs/ardour/audioengine.cc @@ -342,6 +342,18 @@ AudioEngine::process_callback (nframes_t nframes) boost::shared_ptr p = ports.reader(); + for (Ports::iterator i = p->begin(); i != p->end(); ++i) { + + /* Only run cycle_start() on output ports, because + inputs must be done in the correct processing order, + which requires interleaving with route processing. + */ + + if ((*i)->sends_output()) { + (*i)->cycle_start (nframes, 0); + } + } + if (_freewheeling) { /* emit the Freewheel signal and stop freewheeling in the event of trouble */ if (Freewheel (nframes)) { @@ -509,7 +521,9 @@ AudioEngine::set_session (Session *s) boost::shared_ptr p = ports.reader(); for (Ports::iterator i = p->begin(); i != p->end(); ++i) { - (*i)->cycle_start (blocksize, 0); + if ((*i)->sends_output()) { + (*i)->cycle_start (blocksize, 0); + } } s->process (blocksize); diff --git a/libs/ardour/playlist.cc b/libs/ardour/playlist.cc index 65cb8637d5..fbe9990933 100644 --- a/libs/ardour/playlist.cc +++ b/libs/ardour/playlist.cc @@ -467,7 +467,6 @@ void Playlist::add_region (boost::shared_ptr region, nframes_t position, float times) { RegionLock rlock (this); - delay_notifications(); times = fabs (times); int itimes = (int) floor (times); @@ -503,7 +502,6 @@ Playlist::add_region (boost::shared_ptr region, nframes_t position, floa possibly_splice_unlocked (position, (pos + length) - position, boost::shared_ptr()); - release_notifications (); } void