From: "Xu,Randy" <randy...@intel.com> Refer to GLES3.2 spec in 8.5 Textures with a base internal format of DEPTH_COMPONENT, DEPTH_- STENCIL or STENCIL_INDEX are supported by texture image specification commands only if target is TEXTURE_2D, TEXTURE_2D_MULTISAMPLE, TEXTURE_2D_ARRAY, TEXTURE_2D_MULTISAMPLE_ARRAY, TEXTURE_CUBE_- MAP or TEXTURE_CUBE_MAP_ARRAY. Using these formats in conjunction with any other target will result in an INVALID_OPERATION error. This patch can fix dEQP-GLES3.functional.negative_api.texture.teximage3d failure.
Jira: https://01.org/jira/browse/AIA-9 Test: Pass dEQP-GLES3.functional.negative_api.texture.* and no regression. Signed-off-by: Xu,Randy <randy...@intel.com> --- src/mesa/main/glformats.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/mesa/main/glformats.c b/src/mesa/main/glformats.c index a95909c..eeee66b 100644 --- a/src/mesa/main/glformats.c +++ b/src/mesa/main/glformats.c @@ -2087,6 +2087,8 @@ _mesa_error_check_format_and_type(const struct gl_context *ctx, else if (ctx->Extensions.ARB_depth_buffer_float && type == GL_FLOAT_32_UNSIGNED_INT_24_8_REV) return GL_NO_ERROR; + else if (!_mesa_is_desktop_gl(ctx)) + return GL_INVALID_OPERATION; else return GL_INVALID_ENUM; -- 2.7.4 _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev