all repos — mgba @ 57828f6d851f99737735640d0646496a12372aa7

mGBA Game Boy Advance Emulator

3DS: Get input working
Jeffrey Pfau jeffrey@endrift.com
Wed, 10 Dec 2014 03:13:38 -0800
commit

57828f6d851f99737735640d0646496a12372aa7

parent

40d14fe6133b8df8f75be1e9f78a5e4bc7920a92

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

jump to
M src/platform/3ds/main.csrc/platform/3ds/main.c

@@ -42,9 +42,6 @@

renderer.outputBuffer = videoBuffer; renderer.outputBufferStride = VIDEO_HORIZONTAL_PIXELS; - gba->keySource = &activeKeys; - gba->sync = 0; - FS_archive sdmcArchive = (FS_archive) { ARCH_SDMC, (FS_path) { PATH_EMPTY, 1, (u8*)"" },

@@ -59,6 +56,9 @@

GBACreate(gba); ARMSetComponents(cpu, &gba->d, 0, 0); ARMInit(cpu); + + gba->keySource = &activeKeys; + gba->sync = 0; GBAVideoAssociateRenderer(&gba->video, &renderer.d);

@@ -77,6 +77,7 @@ gfxFlushBuffers();

gfxSwapBuffersGpu(); gspWaitForVBlank(); hidScanInput(); + activeKeys = hidKeysHeld() & 0x3FF; } } inVblank = GBARegisterDISPSTATGetInVblank(gba->video.dispstat);