From 9e4a69568943e1309068e4838838305582058fe4 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Mon, 6 Nov 2023 20:28:03 -0700 Subject: [PATCH] temporal: fix error in computation of timecnt_t::end() for specific conditions parens were in the wrong place - we need to add the ::magnitude() of the tick-based duration AFTER conversion of audio-time position to beats, not before. --- libs/temporal/timeline.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/temporal/timeline.cc b/libs/temporal/timeline.cc index bfaf83d076..1dc314277a 100644 --- a/libs/temporal/timeline.cc +++ b/libs/temporal/timeline.cc @@ -126,7 +126,7 @@ timecnt_t::end (TimeDomain return_domain) const } else if (_position.time_domain() == AudioTime) { - const Beats b = TempoMap::use()->quarters_at_superclock (_position.superclocks() + magnitude()); + const Beats b = TempoMap::use()->quarters_at_superclock (_position.superclocks()) + Beats::ticks (magnitude()); if (return_domain == BeatTime) { return timepos_t (b);