From 959f76c843a25b3309a6d180a3a8e914f11dbee7 Mon Sep 17 00:00:00 2001 From: nick_m Date: Sat, 25 Feb 2017 23:32:02 +1100 Subject: make new (ramped) tempi indidstiguishable from constant to the novice user. - stretch drag (using shift on the curve) operates on the true meaning of constant. in other words, the only way you can make a tempo ramped is by adjusting the end tempo (shift drag on the *next* mark). from this point onwards. shift-drag the curve will change the start tempo and ctrl-drag the curve will change the end (needs work). to reset the curve to constant, 'make constant' should simply set the end tempo (unimplemented). --- libs/ardour/tempo.cc | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/libs/ardour/tempo.cc b/libs/ardour/tempo.cc index b1fec3c1ee..8aa6f3953c 100644 --- a/libs/ardour/tempo.cc +++ b/libs/ardour/tempo.cc @@ -3483,7 +3483,10 @@ TempoMap::gui_stretch_tempo (TempoSection* ts, const framepos_t frame, const fra goto out; } - if (prev_t && prev_t->type() == TempoSection::Ramp) { + /* this should be everywhere. no _type because type() is constant if note_types_per_minute() == end_types_per_minute() + but what to do with legact sessions? + */ + if (prev_t && prev_t->note_types_per_minute() != prev_t->end_note_types_per_minute()) { prev_t->set_note_types_per_minute (new_bpm); } else { prev_t->set_end_note_types_per_minute (new_bpm); @@ -3494,7 +3497,7 @@ TempoMap::gui_stretch_tempo (TempoSection* ts, const framepos_t frame, const fra recompute_meters (future_map); if (check_solved (future_map)) { - if (prev_t && prev_t->type() == TempoSection::Ramp) { + if (prev_t && prev_t->note_types_per_minute() != prev_t->end_note_types_per_minute()) { ts->set_note_types_per_minute (new_bpm); } else { ts->set_end_note_types_per_minute (new_bpm); -- cgit v1.2.3