Unverified Commit 0c5cee96 authored by kps501's avatar kps501 Committed by GitHub
Browse files

libretro: hires blending buffer

parent a54da1c0
......@@ -60,6 +60,7 @@ static retro_input_poll_t poll_cb = NULL;
static retro_input_state_t input_state_cb = NULL;
static bool lufia2_credits_hack = false;
static uint16 *gfx_blend;
static void extract_basename(char *buf, const char *path, size_t size)
{
......@@ -884,6 +885,7 @@ void retro_init(void)
GFX.Pitch = MAX_SNES_WIDTH * sizeof(uint16);
GFX.Screen = (uint16*) calloc(1, GFX.Pitch * MAX_SNES_HEIGHT);
gfx_blend = (uint16*) calloc(1, GFX.Pitch * MAX_SNES_HEIGHT);
S9xGraphicsInit();
S9xInitInputDevices();
......@@ -1158,6 +1160,7 @@ void retro_deinit()
S9xUnmapAllControls();
free(GFX.Screen);
free(gfx_blend);
}
......@@ -1306,7 +1309,7 @@ bool8 S9xDeinitUpdate(int width, int height)
for (register int y = 0; y < height; y++)
{
register uint16 *input = (uint16 *) ((uint8 *) GFX.Screen + y * GFX.Pitch);
register uint16 *output = (uint16 *) ((uint8 *) GFX.Screen + y * GFX.Pitch);
register uint16 *output = (uint16 *) ((uint8 *) gfx_blend + y * GFX.Pitch);
register uint16 l, r;
l = 0;
......@@ -1321,9 +1324,14 @@ bool8 S9xDeinitUpdate(int width, int height)
l = r;
}
}
video_cb(gfx_blend, width, height, GFX.Pitch);
}
else
{
video_cb(GFX.Screen, width, height, GFX.Pitch);
}
video_cb(GFX.Screen, width, height, GFX.Pitch);
return TRUE;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment