aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/intel/intel_tex_validate.c
diff options
context:
space:
mode:
authorEric Anholt <[email protected]>2012-10-31 17:00:21 -0700
committerEric Anholt <[email protected]>2012-11-19 15:07:22 -0800
commitbe9e66430763aa2785cbd12d483c7eb9e7055436 (patch)
tree2a35b537765e2c089791f0ab06e22463cc7924d3 /src/mesa/drivers/dri/intel/intel_tex_validate.c
parentc1fabea1c5a40c60176201f55253bd463fd146f5 (diff)
intel: Push face/level -> slice handling to the caller of get_image_offset().
We were always passing 0 for one of the two fields, and the code just used whichever one wasn't 0. Reviewed-by: Chad Versace <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri/intel/intel_tex_validate.c')
-rw-r--r--src/mesa/drivers/dri/intel/intel_tex_validate.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_tex_validate.c b/src/mesa/drivers/dri/intel/intel_tex_validate.c
index 578b4173512..ad173c9d451 100644
--- a/src/mesa/drivers/dri/intel/intel_tex_validate.c
+++ b/src/mesa/drivers/dri/intel/intel_tex_validate.c
@@ -146,7 +146,7 @@ intel_tex_map_image_for_swrast(struct intel_context *intel,
* share code with the normal path.
*/
for (i = 0; i < mt->level[level].depth; i++) {
- intel_miptree_get_image_offset(mt, level, face, i, &x, &y);
+ intel_miptree_get_image_offset(mt, level, i, &x, &y);
intel_image->base.ImageOffsets[i] = x + y * mt->region->pitch;
}
@@ -155,7 +155,7 @@ intel_tex_map_image_for_swrast(struct intel_context *intel,
intel_image->base.Map = intel_region_map(intel, mt->region, mode);
} else {
assert(intel_image->base.Base.Depth == 1);
- intel_miptree_get_image_offset(mt, level, face, 0, &x, &y);
+ intel_miptree_get_image_offset(mt, level, face, &x, &y);
DBG("%s: (%d,%d) -> (%d, %d)/%d\n",
__FUNCTION__, face, level, x, y, mt->region->pitch * mt->cpp);