Mesa (master): i965/miptree/isl: Stop multiplying depth by 6 for cubes
Jason Ekstrand
jekstrand at kemper.freedesktop.org
Tue Jul 26 16:24:34 UTC 2016
Module: Mesa
Branch: master
Commit: 833e389bc00eae419efe4494c297c6c20a89210b
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=833e389bc00eae419efe4494c297c6c20a89210b
Author: Jason Ekstrand <jason.ekstrand at intel.com>
Date: Wed Jul 20 08:22:53 2016 -0700
i965/miptree/isl: Stop multiplying depth by 6 for cubes
Now that the logical_depth0 field is in number of 2D slices, we don't need
to be multiplying by 6 when creating the surface. It wasn't hurting
anything primarily because we get the actual length from the view which was
already handling it correctly.
Signed-off-by: Jason Ekstrand <jason at jlekstrand.net>
Reviewed-by: Anuj Phogat <anuj.phogat at gmail.com>
---
src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 5 -----
1 file changed, 5 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
index 1e03f7e..c8e84b7 100644
--- a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
+++ b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
@@ -3102,11 +3102,6 @@ intel_miptree_get_isl_surf(struct brw_context *brw,
if (surf->dim == ISL_SURF_DIM_3D) {
surf->logical_level0_px.depth = mt->logical_depth0;
surf->logical_level0_px.array_len = 1;
- } else if (mt->target == GL_TEXTURE_CUBE_MAP ||
- mt->target == GL_TEXTURE_CUBE_MAP_ARRAY) {
- /* For cube maps, mt->logical_depth0 is in number of cubes */
- surf->logical_level0_px.depth = 1;
- surf->logical_level0_px.array_len = mt->logical_depth0 * 6;
} else {
surf->logical_level0_px.depth = 1;
surf->logical_level0_px.array_len = mt->logical_depth0;
More information about the mesa-commit
mailing list