aboutsummaryrefslogtreecommitdiff
path: root/frontend
diff options
context:
space:
mode:
authornotaz2014-12-25 00:35:21 +0200
committernotaz2014-12-25 00:35:21 +0200
commitefcf1f7301adbcc06b05eb92fc01a32faa993cfa (patch)
treef1afb1c1b3b053b275748f66d081731060ed9900 /frontend
parent271e11499d7e60e1bfb0ffeda8f8266906130b87 (diff)
downloadpcsx_rearmed-efcf1f7301adbcc06b05eb92fc01a32faa993cfa.tar.gz
pcsx_rearmed-efcf1f7301adbcc06b05eb92fc01a32faa993cfa.tar.bz2
pcsx_rearmed-efcf1f7301adbcc06b05eb92fc01a32faa993cfa.zip
frontend: add 2x scaling option
Diffstat (limited to 'frontend')
-rw-r--r--frontend/menu.c10
-rw-r--r--frontend/menu.h1
-rw-r--r--frontend/plat_omap.c2
-rw-r--r--frontend/plugin_lib.c8
4 files changed, 17 insertions, 4 deletions
diff --git a/frontend/menu.c b/frontend/menu.c
index 2823a23..a37ab05 100644
--- a/frontend/menu.c
+++ b/frontend/menu.c
@@ -391,7 +391,7 @@ static const struct {
CE_CONFIG_VAL(VSyncWA),
CE_CONFIG_VAL(Cpu),
CE_INTVAL(region),
- CE_INTVAL_V(g_scaler, 2),
+ CE_INTVAL_V(g_scaler, 3),
CE_INTVAL(g_gamma),
CE_INTVAL(g_layer_x),
CE_INTVAL(g_layer_y),
@@ -1194,13 +1194,17 @@ static int menu_loop_keyconfig(int id, int keys)
// ------------ gfx options menu ------------
-static const char *men_scaler[] = { "1x1", "scaled 4:3", "integer scaled 4:3", "fullscreen", "custom", NULL };
+static const char *men_scaler[] = {
+ "1x1", "integer scaled 2x", "scaled 4:3", "integer scaled 4:3", "fullscreen", "custom", NULL
+};
static const char *men_soft_filter[] = { "None",
#ifdef __ARM_NEON__
"scale2x", "eagle2x",
#endif
NULL };
static const char *men_dummy[] = { NULL };
+static const char h_scaler[] = "int. 2x - scales w. or h. 2x if it fits on screen\n"
+ "int. 4:3 - uses integer if possible, else fractional";
static const char h_cscaler[] = "Displays the scaler layer, you can resize it\n"
"using d-pad or move it using R+d-pad";
static const char h_overlay[] = "Overlay provides hardware accelerated scaling";
@@ -1261,7 +1265,7 @@ static int menu_loop_cscaler(int id, int keys)
static menu_entry e_menu_gfx_options[] =
{
- mee_enum ("Scaler", MA_OPT_VARSCALER, g_scaler, men_scaler),
+ mee_enum_h ("Scaler", MA_OPT_VARSCALER, g_scaler, men_scaler, h_scaler),
mee_enum ("Video output mode", MA_OPT_VOUT_MODE, plat_target.vout_method, men_dummy),
mee_onoff ("Software Scaling", MA_OPT_SCALER2, soft_scaling, 1),
mee_enum ("Hardware Filter", MA_OPT_HWFILTER, plat_target.hwfilter, men_dummy),
diff --git a/frontend/menu.h b/frontend/menu.h
index 0d68469..6b1e55f 100644
--- a/frontend/menu.h
+++ b/frontend/menu.h
@@ -15,6 +15,7 @@ enum g_opts_opts {
enum g_scaler_opts {
SCALE_1_1,
+ SCALE_2_2,
SCALE_4_3,
SCALE_4_3v2,
SCALE_FULLSCREEN,
diff --git a/frontend/plat_omap.c b/frontend/plat_omap.c
index 6126140..f397cc6 100644
--- a/frontend/plat_omap.c
+++ b/frontend/plat_omap.c
@@ -99,7 +99,7 @@ void *plat_gvideo_set_mode(int *w, int *h, int *bpp)
int l = 0, r = 0, t = 0, b = 0;
void *buf;
- if (g_scaler == SCALE_1_1) {
+ if (g_scaler == SCALE_1_1 || g_scaler == SCALE_2_2) {
if (*w > g_menuscreen_w)
l = r = (*w - g_menuscreen_w) / 2;
if (*h > g_menuscreen_h)
diff --git a/frontend/plugin_lib.c b/frontend/plugin_lib.c
index 72b3395..64f96a0 100644
--- a/frontend/plugin_lib.c
+++ b/frontend/plugin_lib.c
@@ -180,6 +180,14 @@ static void update_layer_size(int w, int h)
g_layer_w = w; g_layer_h = h;
break;
+ case SCALE_2_2:
+ g_layer_w = w; g_layer_h = h;
+ if (w * 2 <= g_menuscreen_w)
+ g_layer_w = w * 2;
+ if (h * 2 <= g_menuscreen_h)
+ g_layer_h = h * 2;
+ break;
+
case SCALE_4_3v2:
if (h > g_menuscreen_h || (240 < h && h <= 360))
goto fractional_4_3;