From b3451f405599a6aa1457da700fbe9bf5bca12781 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Wed, 17 Nov 2021 10:47:00 -0700 Subject: [PATCH] tempo map: fix computation of superclocks_per_note_type_at() Code used position as an absolute, rather than offset from the point that defines tempo. It worked if the point was at zero, but not otherwise. --- libs/temporal/tempo.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/temporal/tempo.cc b/libs/temporal/tempo.cc index 244a582bc1..8fae2d6c35 100644 --- a/libs/temporal/tempo.cc +++ b/libs/temporal/tempo.cc @@ -511,7 +511,7 @@ TempoPoint::superclocks_per_note_type_at (timepos_t const &pos) const return _superclocks_per_note_type; } - return _superclocks_per_note_type * exp (-_omega * pos.superclocks()); + return _superclocks_per_note_type * exp (-_omega * (pos.superclocks() - sclock())); } Temporal::Beats