diff options
author | Michel Dänzer <[email protected]> | 2008-01-14 16:30:58 +0100 |
---|---|---|
committer | Michel Dänzer <[email protected]> | 2008-01-14 16:30:58 +0100 |
commit | 48ae5cf09d733497519328d513c4176bfa1c8fc0 (patch) | |
tree | a38a46eb63632227264527ccb20dd42a9f20648b /src | |
parent | 45cdb6eb456561a948e43b15f5f74618f3173841 (diff) |
i965: Fix byte vs. pixel unit mixup for aligned texture pitch.
I sincerely hope I don't manage to mess this up yet again...
Thanks again to Todd Merrill for pointing out the problem and testing the fix
on IRC.
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c index 78191d10d30..8548bc88bac 100644 --- a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c +++ b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c @@ -128,7 +128,7 @@ int intel_miptree_pitch_align (struct intel_context *intel, int pitch) { if (!mt->compressed) - pitch = (pitch * mt->cpp + 3) & ~3; + pitch = ((pitch * mt->cpp + 3) & ~3) / mt->cpp; return pitch; } |