This is an automated email from the git hooks/post-receive script.

olivier pushed a commit to branch master
in repository xfce/xfwm4.

commit 2321afb386eaceda50bf81ea6ad8c25b12f9f93c
Author: Olivier Fourdan <four...@xfce.org>
Date:   Thu Nov 26 09:15:04 2015 +0100

    compositor: add envvar for Xpresent
    
    Bug: 11861
    
    In some cases, the user may prefer Xpresent over GLX for vsync, if both
    are present, add an environment variable XFWM4_USE_PRESENT for this
    purpose.
    
    Signed-off-by: Olivier Fourdan <four...@xfce.org>
---
 src/compositor.c |   15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)

diff --git a/src/compositor.c b/src/compositor.c
index e441962..dc45218 100644
--- a/src/compositor.c
+++ b/src/compositor.c
@@ -4225,6 +4225,9 @@ compositorManageScreen (ScreenInfo *screen_info)
     XRenderPictureAttributes pa;
     XRenderPictFormat *visual_format;
     gushort buffer;
+#ifdef HAVE_PRESENT_EXTENSION
+    const gchar *use_present_env;
+#endif /* HAVE_PRESENT_EXTENSION */
 
     g_return_val_if_fail (screen_info != NULL, FALSE);
     TRACE ("entering compositorManageScreen");
@@ -4346,7 +4349,17 @@ compositorManageScreen (ScreenInfo *screen_info)
     screen_info->rootTexture = None;
     screen_info->glx_drawable = None;
     screen_info->texture_filter = GL_LINEAR;
-    screen_info->use_glx = init_glx (screen_info);
+#ifdef HAVE_PRESENT_EXTENSION
+    use_present_env = g_getenv ("XFWM4_USE_PRESENT");
+    if (g_strcmp0 (use_present_env, "1") == 0)
+    {
+        screen_info->use_glx = FALSE;
+    }
+    else
+#endif /* HAVE_PRESENT_EXTENSION */
+    {
+        screen_info->use_glx = init_glx (screen_info);
+    }
 #else /* HAVE_EPOXY */
     screen_info->use_glx = FALSE;
 #endif /* HAVE_EPOXY */

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.
_______________________________________________
Xfce4-commits mailing list
Xfce4-commits@xfce.org
https://mail.xfce.org/mailman/listinfo/xfce4-commits

Reply via email to