summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaciej Cencora <m.cencora@gmail.com>2010-07-11 15:39:48 +0200
committerTom Fogal <tfogal@alumni.unh.edu>2010-08-03 12:03:54 -0600
commit7b706cc69b50d26117412c50d8322e0800f7c45a (patch)
treea2da332fe54db97b32fc2277c211f2394ebe2640
parent69088d5484b6b38bd987ef0a34b61ae1a637a7cc (diff)
radeon: lower texture memory consumption is some cases
When searching for valid miptree check images in range of [BaseLeve, MaxLevel] not [MinLod, MaxLoad]. Prevents unnecessary miptree allocations in cases when during every rendering operation different texture image level was selected using MIN_LOD = MAX_LOD = level (for every level new miptree for whole texture was allocated). Candidate for 7.8 branch. Signed-off-by: Maciej Cencora <m.cencora@gmail.com> (cherry picked from commit 72e6a1e72f21653295165320fbca6961eddc9eb3)
-rw-r--r--src/mesa/drivers/dri/radeon/radeon_mipmap_tree.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/radeon/radeon_mipmap_tree.c b/src/mesa/drivers/dri/radeon/radeon_mipmap_tree.c
index 50ba156d3f..f3ce8521a0 100644
--- a/src/mesa/drivers/dri/radeon/radeon_mipmap_tree.c
+++ b/src/mesa/drivers/dri/radeon/radeon_mipmap_tree.c
@@ -588,7 +588,7 @@ int radeon_validate_texture_miptree(GLcontext * ctx, struct gl_texture_object *t
__FUNCTION__, texObj ,t->minLod, t->maxLod);
radeon_mipmap_tree *dst_miptree;
- dst_miptree = get_biggest_matching_miptree(t, t->minLod, t->maxLod);
+ dst_miptree = get_biggest_matching_miptree(t, t->base.BaseLevel, t->base.MaxLevel);
radeon_miptree_unreference(&t->mt);
if (!dst_miptree) {