diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2014-10-12 23:00:14 -0400 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2014-10-12 23:09:35 -0400 |
commit | 7263877f06cf96c62a0a83d18d47f34a7785ec0b (patch) | |
tree | 68c2be409a4d46c5ef7fd200c358737b4c5f001f /libs | |
parent | 6600cf0daae7260e8fbf1e48379e2f91bbb2e7c8 (diff) |
tweak implementation of Session::audible_frame() to be a little more defensible, and correct problems with record align/playhead position while disconnected from physical outputs
Diffstat (limited to 'libs')
-rw-r--r-- | libs/ardour/session.cc | 22 |
1 files changed, 2 insertions, 20 deletions
diff --git a/libs/ardour/session.cc b/libs/ardour/session.cc index 09d69d5738..3bb606806e 100644 --- a/libs/ardour/session.cc +++ b/libs/ardour/session.cc @@ -1469,30 +1469,12 @@ Session::audible_frame () const framepos_t tf; framecnt_t offset; - /* the first of these two possible settings for "offset" - mean that the audible frame is stationary until - audio emerges from the latency compensation - "pseudo-pipeline". - - the second means that the audible frame is stationary - until audio would emerge from a physical port - in the absence of any plugin latency compensation - */ - offset = worst_playback_latency (); - if (offset > current_block_size) { - offset -= current_block_size; - } else { - /* XXX is this correct? if we have no external - physical connections and everything is internal - then surely this is zero? still, how - likely is that anyway? - */ - offset = current_block_size; - } + assert (offset == 0 || offset >= current_block_size); if (synced_to_engine()) { + /* Note: this is basically just sync-to-JACK */ tf = _engine.transport_frame(); } else { tf = _transport_frame; |