Don't grab settings pointer inside video_driver_frame

This commit is contained in:
twinaphex 2021-04-08 20:01:59 +02:00
parent 421dbb19c2
commit 204eaf0e76
2 changed files with 7 additions and 3 deletions

View File

@ -31085,7 +31085,6 @@ static void video_driver_frame(const void *data, unsigned width,
video_driver_pix_fmt = p_rarch->video_driver_pix_fmt;
bool runloop_idle = p_rarch->runloop_idle;
bool video_driver_active = p_rarch->video_driver_active;
settings_t *settings = p_rarch->configuration_settings;
#if defined(HAVE_GFX_WIDGETS)
bool widgets_active = p_rarch->widgets_active;
#endif
@ -31125,9 +31124,9 @@ static void video_driver_frame(const void *data, unsigned width,
if (p_rarch->video_driver_frame_count)
{
unsigned fps_update_interval =
settings->uints.fps_update_interval;
video_info.fps_update_interval;
unsigned memory_update_interval =
settings->uints.memory_update_interval;
video_info.memory_update_interval;
size_t buf_pos = 1;
/* set this to 1 to avoid an offset issue */
unsigned write_index =
@ -31648,6 +31647,9 @@ void video_driver_build_info(video_frame_info_t *video_info)
video_info->msg_bgcolor_enable =
settings->bools.video_msg_bgcolor_enable;
video_info->fps_update_interval = settings->uints.fps_update_interval;
video_info->memory_update_interval = settings->uints.memory_update_interval;
#ifdef HAVE_MENU
video_info->menu_is_alive = p_rarch->menu_driver_alive;
video_info->menu_screensaver_active = p_rarch->menu_driver_state.screensaver_active;

View File

@ -1141,6 +1141,8 @@ typedef struct video_frame_info
unsigned custom_vp_full_width;
unsigned custom_vp_full_height;
unsigned black_frame_insertion;
unsigned fps_update_interval;
unsigned memory_update_interval;
float menu_wallpaper_opacity;
float menu_framebuffer_opacity;