From 463090717bd78240e24cfa52e8b7958d2fd7d646 Mon Sep 17 00:00:00 2001 From: tildearrow Date: Tue, 12 Apr 2022 01:26:14 -0500 Subject: [PATCH] Amiga: what the hell? --- src/engine/platform/amiga.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/engine/platform/amiga.cpp b/src/engine/platform/amiga.cpp index e7b57457e..3da16eef4 100644 --- a/src/engine/platform/amiga.cpp +++ b/src/engine/platform/amiga.cpp @@ -96,6 +96,7 @@ void DivPlatformAmiga::acquire(short* bufL, short* bufR, size_t start, size_t le outL=0; outR=0; for (int i=0; i<4; i++) { + if (!chan[i].active) continue; if (chan[i].useWave || (chan[i].sample>=0 && chan[i].samplesong.sampleLen)) { chan[i].audSub-=AMIGA_DIVIDER; if (chan[i].audSub<0) { @@ -345,7 +346,7 @@ int DivPlatformAmiga::dispatch(DivCommand c) { off=8363.0/(double)s->centerRate; } } - chan[c.chan].baseFreq=round(off*NOTE_PERIODIC_NOROUND(c.value+((chan[c.chan].std.arp.will && !chan[c.chan].std.arp.mode)?(chan[c.chan].std.arp.val-12):(0)))); + chan[c.chan].baseFreq=round(off*NOTE_PERIODIC_NOROUND(c.value+((chan[c.chan].std.arp.will && !chan[c.chan].std.arp.mode)?(chan[c.chan].std.arp.val):(0)))); chan[c.chan].freqChanged=true; chan[c.chan].note=c.value; break;