aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortwinaphex2013-12-31 05:19:20 +0100
committernotaz2014-12-20 02:57:24 +0200
commit0e5a7b7d5a4894754a73d0ea496b3b7b3f6b32d8 (patch)
tree248d1cb0791631f9bc8c22525cd06f49817e8eb6
parent1c2c2bfb00e4040a17f61e7aa2061d446ba44b76 (diff)
downloadpcsx_rearmed-0e5a7b7d5a4894754a73d0ea496b3b7b3f6b32d8.tar.gz
pcsx_rearmed-0e5a7b7d5a4894754a73d0ea496b3b7b3f6b32d8.tar.bz2
pcsx_rearmed-0e5a7b7d5a4894754a73d0ea496b3b7b3f6b32d8.zip
(Libretro) Add frame duping core option
Conflicts: frontend/libretro.c
-rw-r--r--frontend/libretro.c16
1 files changed, 15 insertions, 1 deletions
diff --git a/frontend/libretro.c b/frontend/libretro.c
index 23eecf6..4f6b48e 100644
--- a/frontend/libretro.c
+++ b/frontend/libretro.c
@@ -37,6 +37,7 @@ static void *vout_buf;
static int vout_width, vout_height;
static int vout_doffs_old, vout_fb_dirty;
static bool vout_can_dupe;
+static bool duping_enable;
static int samples_sent, samples_to_send;
static int plugins_opened;
@@ -251,6 +252,7 @@ void retro_set_environment(retro_environment_t cb)
{ "neon_enhancement_enable", "Enhanced resolution (slow); disabled|enabled" },
{ "neon_enhancement_no_main", "Enhanced resolution speed hack; disabled|enabled" },
#endif
+ { "pcsx_rearmed_duping_enable", "Frame duping; on|off" },
{ NULL, NULL },
};
@@ -834,6 +836,18 @@ static void update_variables(bool in_flight)
pl_rearmed_cbs.gpu_neon.enhancement_no_main = 1;
}
#endif
+
+ var.value = "NULL";
+ var.key = "pcsx_rearmed_duping_enable";
+
+ if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var) || var.value)
+ {
+ if (strcmp(var.value, "off") == 0)
+ duping_enable = false;
+ else if (strcmp(var.value, "on") == 0)
+ duping_enable = true;
+ }
+
#ifndef DRC_DISABLE
var.value = NULL;
var.key = "rearmed_drc";
@@ -901,7 +915,7 @@ void retro_run(void)
samples_to_send += is_pal_mode ? 44100 / 50 : 44100 / 60;
- video_cb((vout_fb_dirty || !vout_can_dupe) ? vout_buf : NULL,
+ video_cb((vout_fb_dirty || !vout_can_dupe || !duping_enable) ? vout_buf : NULL,
vout_width, vout_height, vout_width * 2);
vout_fb_dirty = 0;
}