13
0

raptor_arp: Fix looper bug reported in the Ardour forum by Schmitty2005.

This commit is contained in:
Albert Graef 2023-11-20 14:03:56 +01:00 committed by Robin Gareus
parent 520ed0390e
commit 8c38d8fbbc
Signed by: rgareus
GPG Key ID: A090BCE02CF57F04

View File

@ -915,7 +915,7 @@ end
function arpeggio:loop_get() function arpeggio:loop_get()
local res = {{}, 0, 0} local res = {{}, 0, 0}
local p, n = self.loopidx, math.max(1, math.min(#self.loop, self.loopsize)) local p, n = self.loopidx, math.min(#self.loop, self.loopsize)
if p < n then if p < n then
res = self.loop[p+1] res = self.loop[p+1]
-- we always *read* exactly n steps in a cyclic buffer -- we always *read* exactly n steps in a cyclic buffer