mirror of
https://github.com/RaySollium99/picodrive.git
synced 2025-10-27 05:29:39 +01:00
libretro: sound fix and a few options
This commit is contained in:
parent
b08a2950f1
commit
27f190ea00
1 changed files with 21 additions and 1 deletions
|
|
@ -292,6 +292,8 @@ void retro_set_environment(retro_environment_t cb)
|
||||||
//{ "region", "Region; Auto|NTSC|PAL" },
|
//{ "region", "Region; Auto|NTSC|PAL" },
|
||||||
{ "picodrive_input1", "Input device 1; 3 button pad|6 button pad|None" },
|
{ "picodrive_input1", "Input device 1; 3 button pad|6 button pad|None" },
|
||||||
{ "picodrive_input2", "Input device 2; 3 button pad|6 button pad|None" },
|
{ "picodrive_input2", "Input device 2; 3 button pad|6 button pad|None" },
|
||||||
|
{ "picodrive_sprlim", "No sprite limit; disabled|enabled" },
|
||||||
|
{ "picodrive_ramcart", "MegaCD RAM cart; disabled|enabled" },
|
||||||
#ifdef DRC_SH2
|
#ifdef DRC_SH2
|
||||||
{ "picodrive_drc", "Dynamic recompilers; enabled|disabled" },
|
{ "picodrive_drc", "Dynamic recompilers; enabled|disabled" },
|
||||||
#endif
|
#endif
|
||||||
|
|
@ -704,7 +706,7 @@ bool retro_load_game(const struct retro_game_info *info)
|
||||||
PicoWriteSound = snd_write;
|
PicoWriteSound = snd_write;
|
||||||
memset(sndBuffer, 0, sizeof(sndBuffer));
|
memset(sndBuffer, 0, sizeof(sndBuffer));
|
||||||
PsndOut = sndBuffer;
|
PsndOut = sndBuffer;
|
||||||
PsndRerate(1);
|
PsndRerate(0);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
@ -799,6 +801,24 @@ static void update_variables(void)
|
||||||
if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var) && var.value)
|
if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var) && var.value)
|
||||||
PicoSetInputDevice(1, input_name_to_val(var.value));
|
PicoSetInputDevice(1, input_name_to_val(var.value));
|
||||||
|
|
||||||
|
var.value = NULL;
|
||||||
|
var.key = "picodrive_sprlim";
|
||||||
|
if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var) && var.value) {
|
||||||
|
if (strcmp(var.value, "enabled") == 0)
|
||||||
|
PicoOpt |= POPT_DIS_SPRITE_LIM;
|
||||||
|
else
|
||||||
|
PicoOpt &= ~POPT_DIS_SPRITE_LIM;
|
||||||
|
}
|
||||||
|
|
||||||
|
var.value = NULL;
|
||||||
|
var.key = "picodrive_ramcart";
|
||||||
|
if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var) && var.value) {
|
||||||
|
if (strcmp(var.value, "enabled") == 0)
|
||||||
|
PicoOpt |= POPT_EN_MCD_RAMCART;
|
||||||
|
else
|
||||||
|
PicoOpt &= ~POPT_EN_MCD_RAMCART;
|
||||||
|
}
|
||||||
|
|
||||||
#ifdef DRC_SH2
|
#ifdef DRC_SH2
|
||||||
var.value = NULL;
|
var.value = NULL;
|
||||||
var.key = "picodrive_drc";
|
var.key = "picodrive_drc";
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue