GB Audio: Small audio fixes
Jeffrey Pfau jeffrey@endrift.com
Sat, 06 Feb 2016 01:48:28 -0800
1 files changed,
4 insertions(+),
1 deletions(-)
jump to
M
src/gb/audio.c
→
src/gb/audio.c
@@ -121,6 +121,9 @@ audio->ch1.sweepStep = audio->ch1.time;
if (!audio->ch1.control.length) { audio->ch1.control.length = 64; } + if (audio->playingCh1 && audio->ch1.shift) { + audio->playingCh1 = _updateSweep(&audio->ch1); + } audio->nextEvent = 0; } }@@ -360,7 +363,7 @@ audio->ch1.sample = sample * audio->ch1.envelope.currentVolume;
} } - if ((frame & 3) == 2) { + if (audio->ch1.sweepStep && (frame & 3) == 2) { --audio->ch1.sweepStep; if (audio->ch1.sweepStep == 0) { audio->playingCh1 = _updateSweep(&audio->ch1);