Add GB Color Correction core option
This commit is contained in:
parent
02a7a48bf3
commit
aac30c72d3
|
@ -187,6 +187,11 @@ static void set_gbPalette(void)
|
|||
gbPalette[i] = pal[i];
|
||||
}
|
||||
|
||||
static void set_gbColorCorrection(int value)
|
||||
{
|
||||
gbColorOption = value;
|
||||
}
|
||||
|
||||
extern int gbRomType; // gets type from header 0x147
|
||||
extern int gbBattery; // enabled when gbRamSize != 0
|
||||
|
||||
|
@ -1194,6 +1199,15 @@ static void update_variables(bool startup)
|
|||
if (lastpal != current_gbPalette)
|
||||
set_gbPalette();
|
||||
}
|
||||
|
||||
var.key = "vbam_gbcoloroption";
|
||||
var.value = NULL;
|
||||
|
||||
if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var) && var.value)
|
||||
{
|
||||
int val = (!strcmp(var.value, "enabled")) ? 1 : 0;
|
||||
set_gbColorCorrection(val);
|
||||
}
|
||||
}
|
||||
|
||||
// System analog stick range is -0x7fff to 0x7fff
|
||||
|
|
|
@ -145,6 +145,17 @@ struct retro_core_option_definition option_defs_us[] = {
|
|||
},
|
||||
"disabled"
|
||||
},
|
||||
{
|
||||
"vbam_gbcoloroption",
|
||||
"(GB) Color Correction",
|
||||
"Applies color correction which fixes colors in some games games.",
|
||||
{
|
||||
{ "disabled", NULL },
|
||||
{ "enabled", NULL },
|
||||
{ NULL, NULL },
|
||||
},
|
||||
"disabled"
|
||||
},
|
||||
{
|
||||
"vbam_turboenable",
|
||||
"Enable Turbo Buttons",
|
||||
|
|
Loading…
Reference in New Issue