diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2011-02-16 03:25:23 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2011-02-16 03:25:23 +0000 |
commit | bf806a87c3e53d60fa881d91973839f410001c3a (patch) | |
tree | 7947c0239448f12b4b0822f904afd2ee9f99fee9 /libs/ardour/session.cc | |
parent | bdc9dc94b8118dd48db6e25d119a07fa606f8a96 (diff) |
fixes for latency computation and compilation
git-svn-id: svn://localhost/ardour2/branches/3.0@8868 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/session.cc')
-rw-r--r-- | libs/ardour/session.cc | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/libs/ardour/session.cc b/libs/ardour/session.cc index 28822ef6f9..9b461d8c69 100644 --- a/libs/ardour/session.cc +++ b/libs/ardour/session.cc @@ -660,6 +660,7 @@ Session::when_engine_running () BootMessage (_("Connect to engine")); _engine.set_session (this); + _engine.update_total_latencies (); } void @@ -4239,5 +4240,18 @@ void Session::update_latency (bool playback) { DEBUG_TRACE (DEBUG::Latency, "JACK latency callback\n"); + + boost::shared_ptr<RouteList> r = routes.reader (); + + if (playback) { + /* reverse the list so that we work backwards from the last route to run to the first */ + reverse (r->begin(), r->end()); + } + + for (RouteList::iterator i = r->begin(); i != r->end(); ++i) { + DEBUG_TRACE (DEBUG::Latency, string_compose ("------------- Working on latency for %1\n", (*i)->name())); + (*i)->set_latency_ranges (playback); + DEBUG_TRACE (DEBUG::Latency, string_compose ("------------- Done working on latency for %1\n\n", (*i)->name())); + } } #endif |