GB Audio: Initialize wave RAM to GBC values
Jeffrey Pfau jeffrey@endrift.com
Thu, 22 Dec 2016 15:38:34 -0800
2 files changed,
18 insertions(+),
0 deletions(-)
M
CHANGES
→
CHANGES
@@ -59,6 +59,7 @@ - Qt: Move last directory setting from qt.ini to config.ini
- 3DS, PSP2, Wii: Last directory loaded is saved - GB Audio: Simplify envelope code - GB Audio: Improve initial envelope samples + - GB Audio: Initialize wave RAM to GBC values 0.5.1: (2016-10-05) Bugfixes:
M
src/gb/audio.c
→
src/gb/audio.c
@@ -73,6 +73,23 @@ audio->nextCh4 = 0;
audio->ch1 = (struct GBAudioSquareChannel) { .envelope = { .dead = 2 } }; audio->ch2 = (struct GBAudioSquareChannel) { .envelope = { .dead = 2 } }; audio->ch3 = (struct GBAudioWaveChannel) { .bank = 0 }; + // TODO: DMG randomness + audio->ch3.wavedata8[0] = 0x00; + audio->ch3.wavedata8[1] = 0xFF; + audio->ch3.wavedata8[2] = 0x00; + audio->ch3.wavedata8[3] = 0xFF; + audio->ch3.wavedata8[4] = 0x00; + audio->ch3.wavedata8[5] = 0xFF; + audio->ch3.wavedata8[6] = 0x00; + audio->ch3.wavedata8[7] = 0xFF; + audio->ch3.wavedata8[8] = 0x00; + audio->ch3.wavedata8[9] = 0xFF; + audio->ch3.wavedata8[10] = 0x00; + audio->ch3.wavedata8[11] = 0xFF; + audio->ch3.wavedata8[12] = 0x00; + audio->ch3.wavedata8[13] = 0xFF; + audio->ch3.wavedata8[14] = 0x00; + audio->ch3.wavedata8[15] = 0xFF; audio->ch4 = (struct GBAudioNoiseChannel) { .envelope = { .dead = 2 } }; audio->eventDiff = 0; audio->nextFrame = 0;