aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorjuj <jujjyl@gmail.com>2013-12-20 01:21:50 -0800
committerjuj <jujjyl@gmail.com>2013-12-20 01:21:50 -0800
commit0025736920d7f388929d606340e744f53a9dc1a4 (patch)
tree50df520113abf24767558e8dbff2e775cb378afa /tests
parent4efa4270a220da968cd039d724c96a091387b2b9 (diff)
parentc1f5a5b30a53f22e495de4313c81496431b2e759 (diff)
Merge pull request #1934 from juj/eglCreateContext
eglCreateContext.
Diffstat (limited to 'tests')
-rw-r--r--tests/test_egl.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/tests/test_egl.c b/tests/test_egl.c
index 5864a797..d66949d0 100644
--- a/tests/test_egl.c
+++ b/tests/test_egl.c
@@ -37,12 +37,21 @@ int main(int argc, char *argv[])
assert(eglGetError() == EGL_SUCCESS);
assert(surface != 0);
+ // WebGL maps to GLES2. GLES1 is not supported.
+ EGLint contextAttribsOld[] =
+ {
+ EGL_CONTEXT_CLIENT_VERSION, 1,
+ EGL_NONE
+ };
+ EGLContext context = eglCreateContext(display, config, NULL, contextAttribsOld);
+ assert(eglGetError() != EGL_SUCCESS);
+
EGLint contextAttribs[] =
{
EGL_CONTEXT_CLIENT_VERSION, 2,
EGL_NONE
};
- EGLContext context = eglCreateContext(display, config, NULL, contextAttribs);
+ context = eglCreateContext(display, config, NULL, contextAttribs);
assert(eglGetError() == EGL_SUCCESS);
assert(context != 0);