diff options
author | Marek Olšák <[email protected]> | 2014-03-11 15:04:33 +0100 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2014-03-21 00:50:53 +0100 |
commit | 78c60d1b630c2c21dd987ea1bb3713802f22cd29 (patch) | |
tree | 2eb917b4f542eb888e5e70c06e46610256f376d8 /src | |
parent | 185ad78ffddb06d7f1d666ae508cf2fb79712e59 (diff) |
mesa: fix software fallback for generating mipmaps for cube arrays
Cc: [email protected]
Reviewed-by: Brian Paul <[email protected]>
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/main/mipmap.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/mesa/main/mipmap.c b/src/mesa/main/mipmap.c index 521b2d8eb0e..98af0a3a76c 100644 --- a/src/mesa/main/mipmap.c +++ b/src/mesa/main/mipmap.c @@ -1746,6 +1746,7 @@ _mesa_generate_mipmap_level(GLenum target, } break; case GL_TEXTURE_2D_ARRAY_EXT: + case GL_TEXTURE_CUBE_MAP_ARRAY: for (i = 0; i < dstDepth; i++) { make_2d_mipmap(datatype, comps, border, srcWidth, srcHeight, srcData[i], srcRowStride, @@ -1788,7 +1789,8 @@ _mesa_next_mipmap_level_size(GLenum target, GLint border, } if ((srcDepth - 2 * border > 1) && - (target != GL_TEXTURE_2D_ARRAY_EXT)) { + (target != GL_TEXTURE_2D_ARRAY_EXT && + target != GL_TEXTURE_CUBE_MAP_ARRAY)) { *dstDepth = (srcDepth - 2 * border) / 2 + 2 * border; } else { @@ -2029,7 +2031,8 @@ generate_mipmap_compressed(struct gl_context *ctx, GLenum target, /* only two types of compressed textures at this time */ assert(texObj->Target == GL_TEXTURE_2D || texObj->Target == GL_TEXTURE_2D_ARRAY || - texObj->Target == GL_TEXTURE_CUBE_MAP_ARB); + texObj->Target == GL_TEXTURE_CUBE_MAP_ARB || + texObj->Target == GL_TEXTURE_CUBE_MAP_ARRAY); /* * Choose a format for the temporary, uncompressed base image. |