summaryrefslogtreecommitdiff
path: root/libs
diff options
context:
space:
mode:
authornick_m <mainsbridge@gmail.com>2016-06-12 03:26:02 +1000
committernick_m <mainsbridge@gmail.com>2016-06-12 03:26:02 +1000
commitbcf683df0042e5f87013d5a726b8b96c349f24aa (patch)
tree1236045b533bc9a740450443bace63a0f7e2a3d1 /libs
parent24f64b3ea7386ace6d584503fe1397eb4f611dfe (diff)
Fix exact tempo pulse for snap to bars case.
Diffstat (limited to 'libs')
-rw-r--r--libs/ardour/tempo.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/libs/ardour/tempo.cc b/libs/ardour/tempo.cc
index 0ed5a01459..c5c7e2c52f 100644
--- a/libs/ardour/tempo.cc
+++ b/libs/ardour/tempo.cc
@@ -2558,7 +2558,10 @@ TempoMap::gui_move_tempo (TempoSection* ts, const framepos_t& frame, const int&
if (sub_num == -1) {
/* snap to bar */
- pulse = floor (pulse + 0.5);
+ BBT_Time bbt = bbt_at_beat_locked (future_map, beat);
+ bbt.beats = 1;
+ bbt.ticks = 0;
+ pulse = pulse_at_bbt_locked (future_map, bbt);
}
if (solve_map_pulse (future_map, tempo_copy, pulse)) {