diff options
author | Ilia Mirkin <[email protected]> | 2016-02-15 23:57:06 -0500 |
---|---|---|
committer | Ilia Mirkin <[email protected]> | 2016-02-19 12:37:22 -0500 |
commit | a03d6f2aa3bb589ca61c3cc13c4189a973b3a2c1 (patch) | |
tree | 17e8263a4ea3767013e4cf2a02713de49dfc255f /src/mesa/main/glformats.c | |
parent | 2b938a390c15a06be8cf706083890c822979508f (diff) |
mesa: add GL_OES_texture_stencil8 support
It's basically the same thing as GL_ARB_texture_stencil8 except that
glCopyTexImage isn't supported, so add STENCIL_INDEX to the list of
invalid GLES formats for glCopyTexImage.
Signed-off-by: Ilia Mirkin <[email protected]>
Reviewed-by: Eduardo Lima Mitev <[email protected]>
Diffstat (limited to 'src/mesa/main/glformats.c')
-rw-r--r-- | src/mesa/main/glformats.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/mesa/main/glformats.c b/src/mesa/main/glformats.c index f5284447b6e..987cd0db45c 100644 --- a/src/mesa/main/glformats.c +++ b/src/mesa/main/glformats.c @@ -3153,6 +3153,14 @@ _mesa_es3_error_check_format_and_type(const struct gl_context *ctx, } break; + case GL_STENCIL_INDEX: + if (!_mesa_has_OES_texture_stencil8(ctx) || + type != GL_UNSIGNED_BYTE || + internalFormat != GL_STENCIL_INDEX8) { + return GL_INVALID_OPERATION; + } + break; + case GL_ALPHA: case GL_LUMINANCE: case GL_LUMINANCE_ALPHA: |