mirror of
https://git.eden-emu.dev/eden-emu/eden
synced 2026-04-10 03:18:55 +02:00
[frontend] Slow and Turbo modes (#3525)
Closes #3344 Adds slow and turbo modes with configurable speeds that can then be toggled by the user. Behavior is: - Standard/slow limit, toggle turbo = turbo - Turbo limit, toggle turbo = standard - Standard/turbo limit, toggle slow = slow - Slow limit, toggle slow = standard Enabling the turbo/slow mode enables the frame limiter unconditionally. This has some conflicts with VSync. For example when I set my refresh rate to 60hz and enable vsync, turbo mode does nothing. Not sure how to go about fixing this, @MaranBr probably knows better the proper solution. Signed-off-by: crueter <crueter@eden-emu.dev> Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/3525 Reviewed-by: DraVee <dravee@eden-emu.dev> Reviewed-by: CamilleLaVey <camillelavey99@gmail.com>
This commit is contained in:
parent
5f676a6a55
commit
2b979024cb
18 changed files with 295 additions and 29 deletions
|
|
@ -204,6 +204,7 @@ struct Values {
|
|||
true};
|
||||
SwitchableSetting<bool> use_speed_limit{
|
||||
linkage, true, "use_speed_limit", Category::Core, Specialization::Paired, true, true};
|
||||
|
||||
SwitchableSetting<u16, true> speed_limit{linkage,
|
||||
100,
|
||||
0,
|
||||
|
|
@ -214,6 +215,30 @@ struct Values {
|
|||
true,
|
||||
true,
|
||||
&use_speed_limit};
|
||||
|
||||
SwitchableSetting<u16, true> slow_speed_limit{linkage,
|
||||
50,
|
||||
0,
|
||||
9999,
|
||||
"slow_speed_limit",
|
||||
Category::Core,
|
||||
Specialization::Countable | Specialization::Percentage,
|
||||
true,
|
||||
true};
|
||||
|
||||
SwitchableSetting<u16, true> turbo_speed_limit{linkage,
|
||||
200,
|
||||
0,
|
||||
9999,
|
||||
"turbo_speed_limit",
|
||||
Category::Core,
|
||||
Specialization::Countable | Specialization::Percentage,
|
||||
true,
|
||||
true};
|
||||
|
||||
// The currently used speed mode.
|
||||
Setting<SpeedMode> current_speed_mode{linkage, SpeedMode::Standard, "current_speed_mode", Category::Core, Specialization::Default, false, true};
|
||||
|
||||
SwitchableSetting<bool> sync_core_speed{linkage, false, "sync_core_speed", Category::Core,
|
||||
Specialization::Default};
|
||||
|
||||
|
|
@ -824,6 +849,13 @@ bool IsDockedMode();
|
|||
|
||||
float Volume();
|
||||
|
||||
// speed limit ops
|
||||
u16 SpeedLimit();
|
||||
void SetSpeedMode(const SpeedMode &mode);
|
||||
void ToggleStandardMode();
|
||||
void ToggleTurboMode();
|
||||
void ToggleSlowMode();
|
||||
|
||||
std::string GetTimeZoneString(TimeZone time_zone);
|
||||
|
||||
void LogSettings();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue