mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 05:11:16 +00:00
Bug 1736621 - [X11][EGL] Ensure to use the same swap interval as on Wayland, r=stransky,gfx-reviewers,jgilbert
While no issues with these cases are known yet, there is no reason why we would want this case to diverge between Wayland and X11. Spotted by Darkspirit. Differential Revision: https://phabricator.services.mozilla.com/D128910
This commit is contained in:
parent
f56bbf1ce2
commit
c3731eafe0
@ -307,9 +307,8 @@ already_AddRefed<GLContext> GLContextEGLFactory::CreateImpl(
|
||||
gl->MakeCurrent();
|
||||
gl->SetIsDoubleBuffered(doubleBuffered);
|
||||
|
||||
#ifdef MOZ_GTK_WAYLAND
|
||||
if (surface && GdkIsWaylandDisplay()) {
|
||||
// Make eglSwapBuffers() non-blocking on wayland
|
||||
#ifdef MOZ_WIDGET_GTK
|
||||
if (surface) {
|
||||
const int interval = gfxVars::SwapIntervalEGL() ? 1 : 0;
|
||||
egl->fSwapInterval(interval);
|
||||
}
|
||||
@ -500,10 +499,8 @@ bool GLContextEGL::RenewSurface(CompositorWidget* aWidget) {
|
||||
}
|
||||
const bool ok = MakeCurrent(true);
|
||||
MOZ_ASSERT(ok);
|
||||
#ifdef MOZ_GTK_WAYLAND
|
||||
if (mSurface && GdkIsWaylandDisplay()) {
|
||||
// The swap interval pref is false by default so that eglSwapBuffers()
|
||||
// is non-blocking on wayland.
|
||||
#ifdef MOZ_WIDGET_GTK
|
||||
if (mSurface) {
|
||||
const int interval = gfxVars::SwapIntervalEGL() ? 1 : 0;
|
||||
mEgl->fSwapInterval(interval);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user