diff options
author | Eric Anholt <eric@anholt.net> | 2008-09-12 15:48:13 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2008-09-12 15:48:13 -0700 |
commit | 8db761409dadc2e899d4e7107eff3aa07b07aa11 (patch) | |
tree | cc398df6f9be467f384d029bd1d6e3e3c106169c /src/mesa/drivers/dri/intel/intel_mipmap_tree.c | |
parent | bdc8ac4ae2c711e2569618136bf7d9c7b25be53e (diff) | |
download | external_mesa3d-8db761409dadc2e899d4e7107eff3aa07b07aa11.zip external_mesa3d-8db761409dadc2e899d4e7107eff3aa07b07aa11.tar.gz external_mesa3d-8db761409dadc2e899d4e7107eff3aa07b07aa11.tar.bz2 |
intel: Add a width field to regions, and use it for making miptrees in TFP.
Otherwise, we would use the pitch as width of the texture, and compiz would
render the pitch padding on the right hand side.
Diffstat (limited to 'src/mesa/drivers/dri/intel/intel_mipmap_tree.c')
-rw-r--r-- | src/mesa/drivers/dri/intel/intel_mipmap_tree.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_mipmap_tree.c b/src/mesa/drivers/dri/intel/intel_mipmap_tree.c index 9be7e02..f28fac8 100644 --- a/src/mesa/drivers/dri/intel/intel_mipmap_tree.c +++ b/src/mesa/drivers/dri/intel/intel_mipmap_tree.c @@ -117,7 +117,10 @@ intel_miptree_create(struct intel_context *intel, return NULL; mt->region = intel_region_alloc(intel, - mt->cpp, mt->pitch, mt->total_height); + mt->cpp, + mt->pitch, + mt->total_height, + mt->pitch); if (!mt->region) { free(mt); @@ -141,7 +144,7 @@ intel_miptree_create_for_region(struct intel_context *intel, mt = intel_miptree_create_internal(intel, target, internal_format, first_level, last_level, - region->pitch, region->height, depth0, + region->width, region->height, 1, region->cpp, compress_byte); if (!mt) return mt; |