summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/getstring.c
diff options
context:
space:
mode:
authorIan Romanick <[email protected]>2015-04-28 13:13:47 -0700
committerIan Romanick <[email protected]>2015-05-28 16:56:31 -0700
commit1fe243938b11be740417cf016d8c50cd69228628 (patch)
tree4efc775d9d4a03aaaf70d7e2976315b5d7e34ccb /src/mesa/main/getstring.c
parent366ceacf72258a4a81d9c6b412dd565a4c611b17 (diff)
mesa/es3.1: Enable ES 3.1 API and shading language version
This is a bit of a hack for now. Several of the extensions required for OpenGL ES 3.1 have no support, at all, in Mesa. However, with this patch and a patch to allow MESA_GL_VERSION_OVERRIDE to work with ES contexts, people can begin testing the ES "version" of the functionality that is supported. Signed-off-by: Ian Romanick <[email protected]> Reviewed-by: Tapani Pälli <[email protected]>
Diffstat (limited to 'src/mesa/main/getstring.c')
-rw-r--r--src/mesa/main/getstring.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/src/mesa/main/getstring.c b/src/mesa/main/getstring.c
index 1b2c7f054f6..72d99ca4e22 100644
--- a/src/mesa/main/getstring.c
+++ b/src/mesa/main/getstring.c
@@ -72,10 +72,18 @@ shading_language_version(struct gl_context *ctx)
break;
case API_OPENGLES2:
- return (ctx->Version < 30)
- ? (const GLubyte *) "OpenGL ES GLSL ES 1.0.16"
- : (const GLubyte *) "OpenGL ES GLSL ES 3.00";
-
+ switch (ctx->Version) {
+ case 20:
+ return (const GLubyte *) "OpenGL ES GLSL ES 1.0.16";
+ case 30:
+ return (const GLubyte *) "OpenGL ES GLSL ES 3.00";
+ case 31:
+ return (const GLubyte *) "OpenGL ES GLSL ES 3.10";
+ default:
+ _mesa_problem(ctx,
+ "Invalid OpenGL ES version in shading_language_version()");
+ return (const GLubyte *) 0;
+ }
case API_OPENGLES:
/* fall-through */