diff options
author | nick_m <mainsbridge@gmail.com> | 2016-11-04 01:21:57 +1100 |
---|---|---|
committer | nick_m <mainsbridge@gmail.com> | 2016-11-11 03:37:08 +1100 |
commit | 1fa7c0d829d673e6a1ffbb94bade9b0d60a02b44 (patch) | |
tree | 00bd6d1136b0ff6dcc7226d520866e2bcee2e69f /libs/ardour/tempo.cc | |
parent | 594137f5cc5d641873b9002c28453166e81bac9e (diff) |
remove remaining frame api from TempoSection.
Diffstat (limited to 'libs/ardour/tempo.cc')
-rw-r--r-- | libs/ardour/tempo.cc | 25 |
1 files changed, 4 insertions, 21 deletions
diff --git a/libs/ardour/tempo.cc b/libs/ardour/tempo.cc index 3410646a8c..344fd73e7c 100644 --- a/libs/ardour/tempo.cc +++ b/libs/ardour/tempo.cc @@ -282,17 +282,9 @@ TempoSection::pulse_at_tempo (const double& bpm, const double& m) const return _pulse_at_tempo (bpm) + pulse(); } -/** returns the zero-based pulse (relative to session origin) - where the zero-based frame (relative to session) - lies. +/** returns the pulse at the supplied session-relative minute. */ double -TempoSection::pulse_at_frame (const framepos_t& f) const -{ - return pulse_at_minute (minute_at_frame (f)); -} - -double TempoSection::pulse_at_minute (const double& m) const { if (_type == Constant || _c_func == 0.0) { @@ -302,17 +294,8 @@ TempoSection::pulse_at_minute (const double& m) const return _pulse_at_time (m - minute()) + pulse(); } -/** returns the zero-based frame (relative to session start frame) - where the zero-based pulse (relative to session start) - falls. +/** returns the minute (relative to session start) at the supplied pulse. */ - -framepos_t -TempoSection::frame_at_pulse (const double& p) const -{ - return frame_at_minute (minute_at_pulse (p)); -} - double TempoSection::minute_at_pulse (const double& p) const { @@ -3219,8 +3202,8 @@ TempoMap::gui_dilate_tempo (TempoSection* ts, const framepos_t& frame, const fra const frameoffset_t prev_t_frame_contribution = fr_off - (contribution * (double) fr_off); - const double start_pulse = prev_t->pulse_at_frame (frame); - const double end_pulse = prev_t->pulse_at_frame (end_frame); + const double start_pulse = prev_t->pulse_at_minute (minute_at_frame (frame)); + const double end_pulse = prev_t->pulse_at_minute (minute_at_frame (end_frame)); double new_bpm; |