summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/varray.c
diff options
context:
space:
mode:
authorKevin Strasser <[email protected]>2016-10-10 14:29:58 -0700
committerKenneth Graunke <[email protected]>2016-11-09 14:35:20 -0800
commit1d6fe13c138efb836a28052b16260a258d113827 (patch)
tree2552b90dafa1cce30e3746926c2960b004a49e91 /src/mesa/main/varray.c
parentaeaf21ab3e6cb3e628ff0219461cbd06f3a99d34 (diff)
mesa/extensions: expose OES_vertex_half_float for ES2
Half float support already exists for desktop GL. Reuse the ARB_half_float_vertex enable bit and account for the different enum to enable the extension for ES2. Signed-off-by: Kevin Strasser <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/mesa/main/varray.c')
-rw-r--r--src/mesa/main/varray.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/mesa/main/varray.c b/src/mesa/main/varray.c
index 656cb3479c7..c4283551882 100644
--- a/src/mesa/main/varray.c
+++ b/src/mesa/main/varray.c
@@ -102,6 +102,7 @@ type_to_bit(const struct gl_context *ctx, GLenum type)
case GL_UNSIGNED_INT:
return UNSIGNED_INT_BIT;
case GL_HALF_FLOAT:
+ case GL_HALF_FLOAT_OES:
if (ctx->Extensions.ARB_half_float_vertex)
return HALF_BIT;
else
@@ -236,8 +237,10 @@ get_legal_types_mask(const struct gl_context *ctx)
legalTypesMask &= ~(UNSIGNED_INT_BIT |
INT_BIT |
UNSIGNED_INT_2_10_10_10_REV_BIT |
- INT_2_10_10_10_REV_BIT |
- HALF_BIT);
+ INT_2_10_10_10_REV_BIT);
+
+ if (!_mesa_has_OES_vertex_half_float(ctx))
+ legalTypesMask &= ~HALF_BIT;
}
}
else {