GBA BIOS: Fix reloading video registers after reset (fixes #1808)
Vicki Pfau vi@endrift.com
Wed, 24 Jun 2020 18:09:07 -0700
2 files changed,
6 insertions(+),
0 deletions(-)
M
CHANGES
→
CHANGES
@@ -14,6 +14,7 @@ - GB Video: Fix state after skipping BIOS (fixes mgba.io/i/1715 and mgba.io/i/1716)
- GBA: Fix timing advancing too quickly in rare cases - GBA BIOS: Implement dummy sound driver calls - GBA BIOS: Improve HLE BIOS timing + - GBA BIOS: Fix reloading video registers after reset (fixes mgba.io/i/1808) - GBA DMA: Linger last DMA on bus (fixes mgba.io/i/301 and mgba.io/i/1320) - GBA Memory: Improve gamepak prefetch timing - GBA SIO: Fix copying Normal mode transfer values
M
src/gba/bios.c
→
src/gba/bios.c
@@ -179,6 +179,11 @@ cpu->memory.store16(cpu, BASE_IO | 0x208, 0, 0);
} if (registers & 0x9C) { gba->video.renderer->reset(gba->video.renderer); + gba->video.renderer->writeVideoRegister(gba->video.renderer, REG_DISPCNT, gba->memory.io[REG_DISPCNT >> 1]); + int i; + for (i = REG_BG0CNT; i < REG_SOUND1CNT_LO; i += 2) { + gba->video.renderer->writeVideoRegister(gba->video.renderer, i, gba->memory.io[i >> 1]); + } } }