all repos — mgba @ ff03bcf0f0a1aa39a15619102c95eb8bd7255a93

mGBA Game Boy Advance Emulator

Fix MidiKey2Freq
Jeffrey Pfau jeffrey@endrift.com
Sat, 20 Apr 2013 14:46:53 -0700
commit

ff03bcf0f0a1aa39a15619102c95eb8bd7255a93

parent

18fae08450b7cbbce9cf740f5b667db01986c70c

1 files changed, 1 insertions(+), 1 deletions(-)

jump to
M src/gba/gba-bios.csrc/gba/gba-bios.c

@@ -72,7 +72,7 @@ }

static void _MidiKey2Freq(struct GBA* gba) { uint32_t key = GBALoad32(&gba->memory.d, gba->cpu.gprs[0] + 4); - gba->cpu.gprs[0] = key / pow(2, (180 - gba->cpu.gprs[1] - gba->cpu.gprs[2] / 256) / 12); + gba->cpu.gprs[0] = key / powf(2, (180.f - gba->cpu.gprs[1] - gba->cpu.gprs[2] / 256.f) / 12.f); } void GBASwi16(struct ARMBoard* board, int immediate) {