Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use video refresh rate for menu frame limiting #15886

Merged
merged 1 commit into from
Nov 10, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions runloop.c
Original file line number Diff line number Diff line change
Expand Up @@ -6947,9 +6947,14 @@ int runloop_iterate(void)
#endif
#endif
#ifdef HAVE_MENU
/* Always run menu in 1x speed. */
/* Always run menu in video refresh rate speed. */
if (menu_state_get_ptr()->flags & MENU_ST_FLAG_ALIVE)
runloop_set_frame_limit(&video_st->av_info, 1.0f);
{
float refresh_rate = video_driver_get_refresh_rate();

runloop_st->frame_limit_minimum_time = (retro_time_t)
roundf(1000000.0f / ((refresh_rate) ? refresh_rate : settings->floats.video_refresh_rate));
}
else
runloop_set_frame_limit(&video_st->av_info, settings->floats.fastforward_ratio);
#endif
Expand Down
Loading