diff options
author | Robin Gareus <robin@gareus.org> | 2012-11-04 06:31:49 +0000 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2012-11-04 06:31:49 +0000 |
commit | 0ede2d0088d6ffdbde8a2c9ec40c457e98bdabe9 (patch) | |
tree | 3da3b5ff006ae44290659f3695a5064ffb3d97c1 /libs/ardour/session_ltc.cc | |
parent | fd9ca8354e5f9866c193def92c71f237ff1bc388 (diff) |
LTC generator fix latency compensation.
thinko: the generated timecode is offset and
not the timestamp when to send it.
git-svn-id: svn://localhost/ardour2/branches/3.0@13377 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/session_ltc.cc')
-rw-r--r-- | libs/ardour/session_ltc.cc | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/libs/ardour/session_ltc.cc b/libs/ardour/session_ltc.cc index 599813760f..c0d98948fb 100644 --- a/libs/ardour/session_ltc.cc +++ b/libs/ardour/session_ltc.cc @@ -195,18 +195,11 @@ Session::ltc_tx_send_time_code_for_cycle (framepos_t start_frame, framepos_t end #define SIGNUM(a) ( (a) < 0 ? -1 : 1) bool speed_changed = false; - /* use port latency compensation */ -#if 1 - /* The generated timecode is offset by the port-latency, + /* port latency compensation: + * The _generated timecode_ is offset by the port-latency, * therefore the offset depends on the direction of transport. */ - framepos_t cycle_start_frame = (current_speed < 0) ? (start_frame + ltc_out_latency.max) : (start_frame - ltc_out_latency.max); -#else - /* This comes in handy when testing sync - record output on an A3 track - * see also http://tracker.ardour.org/view.php?id=5073 - */ - framepos_t cycle_start_frame = start_frame; -#endif + framepos_t cycle_start_frame = (current_speed < 0) ? (start_frame - ltc_out_latency.max) : (start_frame + ltc_out_latency.max); /* cycle-start may become negative due to latency compensation */ if (cycle_start_frame < 0) { cycle_start_frame = 0; } |