summaryrefslogtreecommitdiff
path: root/gst.c
diff options
context:
space:
mode:
authorMichael Pavone <pavone@retrodev.com>2016-12-27 11:31:17 -0800
committerMichael Pavone <pavone@retrodev.com>2016-12-27 11:31:17 -0800
commita876a34cc5b127dc36ae420eaf9670cccf027492 (patch)
tree2224c2e874a806db27589b778e65aac6399b4360 /gst.c
parent5543eda6041753f6eebf2b99f6f6d5f1ef3ba3ab (diff)
Somewhat broken implementation of Mode 4
Diffstat (limited to 'gst.c')
-rw-r--r--gst.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/gst.c b/gst.c
index e2bc95c..44fe339 100644
--- a/gst.c
+++ b/gst.c
@@ -234,10 +234,7 @@ uint8_t vdp_load_gst(vdp_context * context, FILE * state_file)
}
for (int i = 0; i < CRAM_SIZE; i++) {
uint16_t value;
- context->cram[i] = value = (tmp_buf[i*2+1] << 8) | tmp_buf[i*2];
- context->colors[i] = color_map[value & 0xEEE];
- context->colors[i + CRAM_SIZE] = color_map[(value & 0xEEE) | FBUF_SHADOW];
- context->colors[i + CRAM_SIZE*2] = color_map[(value & 0xEEE) | FBUF_HILIGHT];
+ write_cram(context, i, (tmp_buf[i*2+1] << 8) | tmp_buf[i*2]);
}
if (fread(tmp_buf, 2, VSRAM_SIZE, state_file) != VSRAM_SIZE) {
fputs("Failed to read VSRAM from savestate\n", stderr);