From: Ian Romanick Date: Wed, 16 Jan 2013 23:34:26 +0000 (-0800) Subject: mesa: Don't allow DEPTH_STENCIL for 3D textures X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=311cc5d973115465cb7b0e272702e14124478ded;p=mesa.git mesa: Don't allow DEPTH_STENCIL for 3D textures Just like DEPTH_COMPONENT. Signed-off-by: Ian Romanick Reviewed-by: Kenneth Graunke Reviewed-by: Anuj Phogat --- diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c index 5e451e235d4..99b145ef77d 100644 --- a/src/mesa/main/teximage.c +++ b/src/mesa/main/teximage.c @@ -2006,7 +2006,8 @@ texture_error_check( struct gl_context *ctx, } /* additional checks for depth textures */ - if (_mesa_base_tex_format(ctx, internalFormat) == GL_DEPTH_COMPONENT) { + if (_mesa_base_tex_format(ctx, internalFormat) == GL_DEPTH_COMPONENT + || _mesa_base_tex_format(ctx, internalFormat) == GL_DEPTH_STENCIL) { /* Only 1D, 2D, rect, array and cube textures supported, not 3D * Cubemaps are only supported for GL version > 3.0 or with EXT_gpu_shader4 */ if (target != GL_TEXTURE_1D &&