Work around mesa's default-on swap control

This commit is contained in:
Dan Elkouby 2018-12-14 19:22:45 +02:00
parent de1cce21ba
commit e2182bb00b

View File

@ -4630,6 +4630,9 @@ vsync_opengl_swc_deinit(session_t *ps) {
*/
bool
vsync_init(session_t *ps) {
// Mesa turns on swap control by default, undo that
vsync_opengl_swc_swap_interval(ps, 0);
if (ps->o.vsync && VSYNC_FUNCS_INIT[ps->o.vsync]
&& !VSYNC_FUNCS_INIT[ps->o.vsync](ps)) {
ps->o.vsync = VSYNC_NONE;