mesa: Don't allow DEPTH_STENCIL for 3D textures
Just like DEPTH_COMPONENT. Signed-off-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
This commit is contained in:
parent
57ddf1227f
commit
311cc5d973
|
@ -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 &&
|
||||
|
|
Loading…
Reference in New Issue