all repos — mgba @ 3d402f6afda8cb79e84110146d60843cb046708a

mGBA Game Boy Advance Emulator

GBA Core: Only associate renderer if it has an output buffer
Jeffrey Pfau jeffrey@endrift.com
Sun, 07 Feb 2016 15:08:12 -0800
commit

3d402f6afda8cb79e84110146d60843cb046708a

parent

eccddde2834544da2ce62dfb3abe2c596207bd5f

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

jump to
M src/gba/core.csrc/gba/core.c

@@ -152,7 +152,9 @@

static void _GBACoreReset(struct mCore* core) { struct GBACore* gbacore = (struct GBACore*) core; struct GBA* gba = (struct GBA*) core->board; - GBAVideoAssociateRenderer(&gba->video, &gbacore->renderer.d); + if (gbacore->renderer.outputBuffer) { + GBAVideoAssociateRenderer(&gba->video, &gbacore->renderer.d); + } ARMReset(core->cpu); if (core->opts.skipBios) { GBASkipBIOS(core->board);