From 35879fe8295cca5483d4eb42e19298e36c00b903 Mon Sep 17 00:00:00 2001 From: Jason Ekstrand Date: Fri, 22 Jan 2016 16:13:36 -0800 Subject: [PATCH] gen8/state: Divide depth by 6 for cube maps for GEN8 For Broadwell cube maps, MinimumArrayElement is in terms of 2d slices (a multiple of 6) but Depth is in terms of whole cubes. --- src/vulkan/gen8_state.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vulkan/gen8_state.c b/src/vulkan/gen8_state.c index 823bfa0..3c9d152 100644 --- a/src/vulkan/gen8_state.c +++ b/src/vulkan/gen8_state.c @@ -270,7 +270,7 @@ genX(fill_image_surface_state)(struct anv_device *device, void *state_map, #else /* Same as SURFTYPE_2D */ template.MinimumArrayElement = range->baseArrayLayer; - template.Depth = range->layerCount - 1; + template.Depth = range->layerCount / 6 - 1; template.RenderTargetViewExtent = template.Depth; #endif break; -- 2.7.4