public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] gentoo-x86 commit in x11-libs/cairo/files: cairo-1.12.2-surfaceless-extension.patch
@ 2012-09-12  5:24 Matt Turner (mattst88)
  0 siblings, 0 replies; only message in thread
From: Matt Turner (mattst88) @ 2012-09-12  5:24 UTC (permalink / raw
  To: gentoo-commits

mattst88    12/09/12 05:24:57

  Added:                cairo-1.12.2-surfaceless-extension.patch
  Log:
  Add patch for bug 431014 to fix EGL surfaceless extension detection.
  
  (Portage version: 2.1.11.9/cvs/Linux x86_64)

Revision  Changes    Path
1.1                  x11-libs/cairo/files/cairo-1.12.2-surfaceless-extension.patch

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/x11-libs/cairo/files/cairo-1.12.2-surfaceless-extension.patch?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/x11-libs/cairo/files/cairo-1.12.2-surfaceless-extension.patch?rev=1.1&content-type=text/plain

Index: cairo-1.12.2-surfaceless-extension.patch
===================================================================
commit f59b0914f4ddbff0d116c918343a6726d5f4317b
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date:   Sat Aug 11 17:38:36 2012 +0100

    egl: s/EGL_KHR_surfaceless_opengl/EGL_KHR_surfaceless_context/
    
    Mesa changed the name of the extension it invented, so check for the
    real name and the old name before falling back to pbuffers which are not
    supported by most EGL implementations.
    
    References: https://bugs.freedesktop.org/show_bug.cgi?id=53361
    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>

diff --git a/src/cairo-egl-context.c b/src/cairo-egl-context.c
index eb1ef29..b24bc80 100644
--- a/src/cairo-egl-context.c
+++ b/src/cairo-egl-context.c
@@ -122,8 +122,10 @@ _egl_make_current_surfaceless(cairo_egl_context_t *ctx)
     const char *extensions;
 
     extensions = eglQueryString(ctx->display, EGL_EXTENSIONS);
-    if (!strstr(extensions, "EGL_KHR_surfaceless_opengl"))
+    if (strstr(extensions, "EGL_KHR_surfaceless_context") == NULL &&
+	strstr(extensions, "EGL_KHR_surfaceless_opengl") == NULL)
 	return FALSE;
+
     if (!eglMakeCurrent(ctx->display,
 			EGL_NO_SURFACE, EGL_NO_SURFACE, ctx->context))
 	return FALSE;
@@ -174,7 +176,6 @@ cairo_egl_device_create (EGLDisplay dpy, EGLContext egl)
 	eglChooseConfig (dpy, config_attribs, &config, 1, &numConfigs);
 
 	ctx->dummy_surface = eglCreatePbufferSurface (dpy, config, attribs);
-
 	if (ctx->dummy_surface == NULL) {
 	    free (ctx);
 	    return _cairo_gl_context_create_in_error (CAIRO_STATUS_NO_MEMORY);





^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2012-09-12  5:25 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-09-12  5:24 [gentoo-commits] gentoo-x86 commit in x11-libs/cairo/files: cairo-1.12.2-surfaceless-extension.patch Matt Turner (mattst88)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox