Mesa (master): mesa: Fix MaxNumLayers for 1D array textures.
Kenneth Graunke
kwg at kemper.freedesktop.org
Thu May 8 06:41:18 UTC 2014
Module: Mesa
Branch: master
Commit: 5c399ca8e4ccae509a5116b3b9f41634a7ca4322
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=5c399ca8e4ccae509a5116b3b9f41634a7ca4322
Author: Kenneth Graunke <kenneth at whitecape.org>
Date: Wed May 7 14:35:42 2014 -0700
mesa: Fix MaxNumLayers for 1D array textures.
1D array targets store the number of slices in the Height field.
Cc: "10.2 10.1 10.0" <mesa-stable at lists.freedesktop.org>
Signed-off-by: Kenneth Graunke <kenneth at whitecape.org>
Reviewed-by: Brian Paul <brianp at vmware.com>
Reviewed-by: Marek Olšák <marek.olsak at amd.com>
Reviewed-by: Jordan Justen <jordan.l.justen at intel.com>
---
src/mesa/main/fbobject.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c
index ca16ae1..97538bc 100644
--- a/src/mesa/main/fbobject.c
+++ b/src/mesa/main/fbobject.c
@@ -1058,6 +1058,8 @@ _mesa_test_framebuffer_completeness(struct gl_context *ctx,
if (att->Layered) {
if (att_tex_target == GL_TEXTURE_CUBE_MAP)
att_layer_count = 6;
+ else if (att_tex_target == GL_TEXTURE_1D_ARRAY)
+ att_layer_count = att->Renderbuffer->Height;
else
att_layer_count = att->Renderbuffer->Depth;
} else {
More information about the mesa-commit
mailing list