GB Core: Add reload config option for SGB borders
Vicki Pfau vi@endrift.com
Sun, 11 Oct 2020 22:42:23 -0700
2 files changed,
6 insertions(+),
1 deletions(-)
M
src/gb/core.c
→
src/gb/core.c
@@ -277,6 +277,12 @@ gb->allowOpposingDirections = fakeBool;
} return; } + if (strcmp("sgb.borders", option) == 0) { + if (mCoreConfigGetIntValue(config, "sgb.borders", &fakeBool)) { + gb->video.sgbBorders = fakeBool; + gb->video.renderer->enableSGBBorder(gb->video.renderer, fakeBool); + } + } } static void _GBCoreDesiredVideoDimensions(struct mCore* core, unsigned* width, unsigned* height) {
M
src/gb/serialize.c
→
src/gb/serialize.c
@@ -247,7 +247,6 @@ }
if (gb->video.renderer->sgbAttributes) { memcpy(state->sgb.attributes, gb->video.renderer->sgbAttributes, sizeof(state->sgb.attributes)); } - gb->video.renderer->enableSGBBorder(gb->video.renderer, gb->video.sgbBorders); } void GBSGBDeserialize(struct GB* gb, const struct GBSerializedState* state) {