summaryrefslogtreecommitdiffstats
path: root/src/egl/main/eglconfig.c
diff options
context:
space:
mode:
authorChia-I Wu <[email protected]>2010-01-31 14:39:06 +0800
committerChia-I Wu <[email protected]>2010-01-31 14:46:15 +0800
commitbbdce27649698df82432f8da4dc3740c508d3ed8 (patch)
tree99bb2130284ea385026b8a491f35acb82979f449 /src/egl/main/eglconfig.c
parent216925ccd122a06505dafae425323e3ac858f80e (diff)
egl: Surface type validaction should depend on extensions supported.
EGL_SCREEN_BIT_MESA is a valid bit only when EGL_MESA_screen_surface is supported.
Diffstat (limited to 'src/egl/main/eglconfig.c')
-rw-r--r--src/egl/main/eglconfig.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/egl/main/eglconfig.c b/src/egl/main/eglconfig.c
index 1a5fdbd4250..635ffee92b2 100644
--- a/src/egl/main/eglconfig.c
+++ b/src/egl/main/eglconfig.c
@@ -325,11 +325,12 @@ _eglValidateConfig(const _EGLConfig *conf, EGLBoolean for_matching)
mask = EGL_PBUFFER_BIT |
EGL_PIXMAP_BIT |
EGL_WINDOW_BIT |
- EGL_SCREEN_BIT_MESA | /* XXX should check the extension */
EGL_VG_COLORSPACE_LINEAR_BIT |
EGL_VG_ALPHA_FORMAT_PRE_BIT |
EGL_MULTISAMPLE_RESOLVE_BOX_BIT |
EGL_SWAP_BEHAVIOR_PRESERVED_BIT;
+ if (conf->Display->Extensions.MESA_screen_surface)
+ mask |= EGL_SCREEN_BIT_MESA;
break;
case EGL_RENDERABLE_TYPE:
case EGL_CONFORMANT: