summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorEric Anholt <[email protected]>2019-05-01 14:01:58 -0700
committerEric Anholt <[email protected]>2019-05-13 12:03:03 -0700
commitce6dbc0417586cc1ceb015b631384ffdfb22e981 (patch)
tree13eaaaa073ed07897a186617a081b1bdca6e534a /src
parentd88f3392fff7c6342f3840c4bd8195a1296c2372 (diff)
mesa: Remove proxy image checks for maximum level.
We've already verified this by _mesa_legal_texture_dimensions() before this call. Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/mesa/main/teximage.c18
1 files changed, 0 insertions, 18 deletions
diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c
index edcb48d9a6d..7d32c7b2db9 100644
--- a/src/mesa/main/teximage.c
+++ b/src/mesa/main/teximage.c
@@ -423,23 +423,15 @@ get_proxy_tex_image(struct gl_context *ctx, GLenum target, GLint level)
switch (target) {
case GL_PROXY_TEXTURE_1D:
- if (level >= ctx->Const.MaxTextureLevels)
- return NULL;
texIndex = TEXTURE_1D_INDEX;
break;
case GL_PROXY_TEXTURE_2D:
- if (level >= ctx->Const.MaxTextureLevels)
- return NULL;
texIndex = TEXTURE_2D_INDEX;
break;
case GL_PROXY_TEXTURE_3D:
- if (level >= ctx->Const.Max3DTextureLevels)
- return NULL;
texIndex = TEXTURE_3D_INDEX;
break;
case GL_PROXY_TEXTURE_CUBE_MAP:
- if (level >= ctx->Const.MaxCubeTextureLevels)
- return NULL;
texIndex = TEXTURE_CUBE_INDEX;
break;
case GL_PROXY_TEXTURE_RECTANGLE_NV:
@@ -448,28 +440,18 @@ get_proxy_tex_image(struct gl_context *ctx, GLenum target, GLint level)
texIndex = TEXTURE_RECT_INDEX;
break;
case GL_PROXY_TEXTURE_1D_ARRAY_EXT:
- if (level >= ctx->Const.MaxTextureLevels)
- return NULL;
texIndex = TEXTURE_1D_ARRAY_INDEX;
break;
case GL_PROXY_TEXTURE_2D_ARRAY_EXT:
- if (level >= ctx->Const.MaxTextureLevels)
- return NULL;
texIndex = TEXTURE_2D_ARRAY_INDEX;
break;
case GL_PROXY_TEXTURE_CUBE_MAP_ARRAY:
- if (level >= ctx->Const.MaxCubeTextureLevels)
- return NULL;
texIndex = TEXTURE_CUBE_ARRAY_INDEX;
break;
case GL_PROXY_TEXTURE_2D_MULTISAMPLE:
- if (level > 0)
- return 0;
texIndex = TEXTURE_2D_MULTISAMPLE_INDEX;
break;
case GL_PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY:
- if (level > 0)
- return 0;
texIndex = TEXTURE_2D_MULTISAMPLE_ARRAY_INDEX;
break;
default: