Bug 981856. Use an 888 config when creating a pbuffer. r=jgilbert
authorJeff Muizelaar <jmuizelaar@mozilla.com>
Fri, 14 Mar 2014 11:24:58 -0400
changeset 191911 a2ec4ab256e819ab40ee73c25e48cfaca788bb35
parent 191910 256dfb415f148bb6aa2ec109bd7108b091bc72b5
child 191912 cc298e4b0f470d1ed70cd92e874b761c58b60fe8
push id474
push userasasaki@mozilla.com
push dateMon, 02 Jun 2014 21:01:02 +0000
treeherdermozilla-release@967f4cf1b31c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjgilbert
bugs981856
milestone30.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 981856. Use an 888 config when creating a pbuffer. r=jgilbert Old versions of llvmpipe (8.0.4) seem to give out 565 configs that it can't actually make PBuffers for. Explicilty ask for 8,8,8 to avoid that problem.
gfx/gl/GLContextProviderEGL.cpp
--- a/gfx/gl/GLContextProviderEGL.cpp
+++ b/gfx/gl/GLContextProviderEGL.cpp
@@ -545,16 +545,21 @@ TRY_AGAIN_POWER_OF_TWO:
     }
 
     return surface;
 }
 
 static const EGLint kEGLConfigAttribsOffscreenPBuffer[] = {
     LOCAL_EGL_SURFACE_TYPE,    LOCAL_EGL_PBUFFER_BIT,
     LOCAL_EGL_RENDERABLE_TYPE, LOCAL_EGL_OPENGL_ES2_BIT,
+    // Old versions of llvmpipe seem to need this to properly create the pbuffer (bug 981856)
+    LOCAL_EGL_RED_SIZE,        8,
+    LOCAL_EGL_GREEN_SIZE,      8,
+    LOCAL_EGL_BLUE_SIZE,       8,
+    LOCAL_EGL_ALPHA_SIZE,      0,
     EGL_ATTRIBS_LIST_SAFE_TERMINATION_WORKING_AROUND_BUGS
 };
 
 static const EGLint kEGLConfigAttribsRGB16[] = {
     LOCAL_EGL_SURFACE_TYPE,    LOCAL_EGL_WINDOW_BIT,
     LOCAL_EGL_RENDERABLE_TYPE, LOCAL_EGL_OPENGL_ES2_BIT,
     LOCAL_EGL_RED_SIZE,        5,
     LOCAL_EGL_GREEN_SIZE,      6,