diff options
Diffstat (limited to 'src/mesa/main')
-rw-r--r-- | src/mesa/main/teximage.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c index b3ce5d95b77..060f34b7f97 100644 --- a/src/mesa/main/teximage.c +++ b/src/mesa/main/teximage.c @@ -888,23 +888,19 @@ _mesa_max_texture_levels(struct gl_context *ctx, GLenum target) /** - * Return number of dimenions per image for the given texture target. + * Return number of dimensions per mipmap level for the given texture target. */ static GLint get_texture_dimensions(GLenum target) { switch (target) { case GL_TEXTURE_1D: - case GL_TEXTURE_1D_ARRAY: case GL_PROXY_TEXTURE_1D: - case GL_PROXY_TEXTURE_1D_ARRAY: return 1; case GL_TEXTURE_2D: - case GL_TEXTURE_2D_ARRAY: case GL_TEXTURE_RECTANGLE: case GL_TEXTURE_CUBE_MAP: case GL_PROXY_TEXTURE_2D: - case GL_PROXY_TEXTURE_2D_ARRAY: case GL_PROXY_TEXTURE_RECTANGLE: case GL_PROXY_TEXTURE_CUBE_MAP: case GL_TEXTURE_CUBE_MAP_POSITIVE_X: @@ -913,9 +909,13 @@ get_texture_dimensions(GLenum target) case GL_TEXTURE_CUBE_MAP_NEGATIVE_Y: case GL_TEXTURE_CUBE_MAP_POSITIVE_Z: case GL_TEXTURE_CUBE_MAP_NEGATIVE_Z: + case GL_TEXTURE_1D_ARRAY: + case GL_PROXY_TEXTURE_1D_ARRAY: return 2; case GL_TEXTURE_3D: case GL_PROXY_TEXTURE_3D: + case GL_TEXTURE_2D_ARRAY: + case GL_PROXY_TEXTURE_2D_ARRAY: return 3; default: _mesa_problem(NULL, "invalid target 0x%x in get_texture_dimensions()", |