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:
parent
c111c33b80
commit
d7cd930d40
4
gfx/gl.c
4
gfx/gl.c
@ -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;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user