diff options
author | nick_m <mainsbridge@gmail.com> | 2015-12-28 05:33:04 +1100 |
---|---|---|
committer | nick_m <mainsbridge@gmail.com> | 2016-05-27 23:38:09 +1000 |
commit | 5c6e18e6a087823e4a3719177c92238b206e3aeb (patch) | |
tree | 25f7faefa65e630e68da70bf4378b825e7c29312 /gtk2_ardour/editor_ops.cc | |
parent | 41c8b534b70e220b4d4b940aed8a98d9a57003ab (diff) |
Tempo ramps - remove the concept of bars from tempo sections.
- this helps where tempo and meter have a somewhat circular
dependency.
MetricSection now has a musical position expressed in beats (a double).
MeterSection still has a bbt, but it really isn't needed as we have
enough information to discover the number of bars at a given beat without it.
TempoSection now has a hack to enable loading of legacy sessions, which will
ultimately be a lot cleaner than the current code.
Removing bars from tempo sections also allows us to place them
at arbitrary frames (implemented here).
Diffstat (limited to 'gtk2_ardour/editor_ops.cc')
-rw-r--r-- | gtk2_ardour/editor_ops.cc | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/gtk2_ardour/editor_ops.cc b/gtk2_ardour/editor_ops.cc index f094c793ac..59a5e8d6db 100644 --- a/gtk2_ardour/editor_ops.cc +++ b/gtk2_ardour/editor_ops.cc @@ -6552,9 +6552,7 @@ Editor::define_one_bar (framepos_t start, framepos_t end) } else if (t.frame() == start) { _session->tempo_map().change_existing_tempo_at (start, beats_per_minute, t.note_type()); } else { - Timecode::BBT_Time bbt; - _session->tempo_map().bbt_time (start, bbt); - _session->tempo_map().add_tempo (Tempo (beats_per_minute, t.note_type()), bbt, TempoSection::Type::Constant); + _session->tempo_map().add_tempo (Tempo (beats_per_minute, t.note_type()), _session->tempo_map().beat_at_frame (start), TempoSection::Type::Constant); } XMLNode& after (_session->tempo_map().get_state()); |