[Mesa-dev] [PATCH 1/2] mesa: Don't allow DEPTH_STENCIL for 3D textures
Ian Romanick
idr at freedesktop.org
Wed Jan 16 15:36:50 PST 2013
From: Ian Romanick <ian.d.romanick at intel.com>
Just like DEPTH_COMPONENT.
Signed-off-by: Ian Romanick <ian.d.romanick at intel.com>
---
src/mesa/main/teximage.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c
index eeb977e..7a15196 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 &&
--
1.7.11.7
More information about the mesa-dev
mailing list