1
0
mirror of https://github.com/libretro/RetroArch synced 2025-03-25 16:44:01 +00:00

Avoid flicker during BFI and slow-motion or pause

This commit is contained in:
Mike Robinson 2014-08-31 11:05:09 +01:00
parent c111c33b80
commit d7cd930d40
2 changed files with 8 additions and 2 deletions

@ -1644,8 +1644,8 @@ static bool gl_frame(void *data, const void *frame, unsigned width, unsigned hei
#endif
#endif
// Disable BFI during fast forward to prevent flicker
if (g_settings.video.black_frame_insertion && !driver.nonblock_state)
// Disable BFI during fast forward, slow-motion, and pause to prevent flicker
if (g_settings.video.black_frame_insertion && !driver.nonblock_state && !g_extern.is_slowmotion && !g_extern.is_paused)
{
context_swap_buffers_func(gl);
glClear(GL_COLOR_BUFFER_BIT);

@ -2270,6 +2270,9 @@ static void check_slowmotion(void)
if (!g_extern.is_slowmotion)
return;
if (g_settings.video.black_frame_insertion)
rarch_render_cached_frame();
msg_queue_clear(g_extern.msg_queue);
msg_queue_push(g_extern.msg_queue, g_extern.frame_is_reverse ?
"Slow motion rewind." : "Slow motion.", 0, 30);
@ -2394,6 +2397,9 @@ static void check_pause(void)
if (has_set_audio_start)
rarch_main_command(RARCH_CMD_AUDIO_START);
if (g_extern.is_paused && g_settings.video.black_frame_insertion)
rarch_render_cached_frame();
old_focus = focus;
old_state = new_state;
}