summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornick_m <mainsbridge@gmail.com>2016-02-29 05:42:22 +1100
committernick_m <mainsbridge@gmail.com>2016-05-27 23:38:10 +1000
commit0f8189928058ee6593b5b4e52e1a0c0a8ee4ce39 (patch)
tree529f21c30bfdb854e05af034ac3a5553edbb3f09
parentc4fe85dd7c39ccab634516fbd89f0c04b825e28a (diff)
Tempo ramps - fixes bbt wrt frame-locked tempo sections in the tempo dialog
-rw-r--r--libs/ardour/tempo.cc9
1 files changed, 7 insertions, 2 deletions
diff --git a/libs/ardour/tempo.cc b/libs/ardour/tempo.cc
index 749042d950..da22da4bd2 100644
--- a/libs/ardour/tempo.cc
+++ b/libs/ardour/tempo.cc
@@ -839,13 +839,18 @@ TempoMap::replace_c_func_from_tempo_and_beat (const double& bpm, const double& b
for (Metrics::iterator i = metrics.begin(); i != metrics.end(); ++i) {
if ((t = dynamic_cast<TempoSection*> (*i)) != 0) {
- if (prev_ts && beat < t->beat()) {
+ if (prev_ts) {
prev_ts->set_c_func_from_tempo_and_beat (bpm, beat, _frame_rate);
- break;
+
+ if (beat < t->beat()) {
+ return;
+ }
}
prev_ts = t;
}
}
+ /* there is always at least one tempo section */
+ prev_ts->set_c_func_from_tempo_and_beat (bpm, beat, _frame_rate);
}
void