diff options
author | Chia-I Wu <[email protected]> | 2009-09-30 12:13:34 +0800 |
---|---|---|
committer | Brian Paul <[email protected]> | 2009-09-30 08:15:30 -0600 |
commit | 28c2190336aec5b0b1d0f74d08e32dc604bcc4c1 (patch) | |
tree | 72632168dce16c5e35ec9fb3c9ff80bdbf85aebd /progs/egl | |
parent | e0b2848f4fadc832f68c3c1a059546684935969d (diff) |
progs/egl: Check EGL_MESA_screen_surface is supported in demo2.
Signed-off-by: Chia-I Wu <[email protected]>
Diffstat (limited to 'progs/egl')
-rw-r--r-- | progs/egl/demo2.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/progs/egl/demo2.c b/progs/egl/demo2.c index 5817771aec8..3994656721f 100644 --- a/progs/egl/demo2.c +++ b/progs/egl/demo2.c @@ -7,6 +7,7 @@ #include <assert.h> #include <stdio.h> #include <stdlib.h> +#include <string.h> #include <unistd.h> #include <EGL/egl.h> @@ -129,6 +130,11 @@ main(int argc, char *argv[]) printf("EGL version = %d.%d\n", maj, min); printf("EGL_VENDOR = %s\n", eglQueryString(d, EGL_VENDOR)); + if (!strstr(eglQueryString(d, EGL_EXTENSIONS), + "EGL_MESA_screen_surface")) { + printf("EGL_MESA_screen_surface is not supported\n"); + exit(1); + } eglGetConfigs(d, configs, 10, &numConfigs); printf("Got %d EGL configs:\n", numConfigs); |