summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri
diff options
context:
space:
mode:
authorXiang, Haihao <haihao.xiang@intel.com>2007-08-31 12:51:36 +0800
committerXiang, Haihao <haihao.xiang@intel.com>2007-08-31 12:51:36 +0800
commit22bc3cdd49eb81d48ad4b8f06be0b9a9de624c91 (patch)
treed404dacaed933b48ccaa068bceded8dc79f3618b /src/mesa/drivers/dri
parent1dd94a63ace0c6133f80191ba3b3e5f56f86c8fe (diff)
i965: Take the upper limitation on LOD into account.
Diffstat (limited to 'src/mesa/drivers/dri')
-rw-r--r--src/mesa/drivers/dri/i965/brw_wm_sampler_state.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_wm_sampler_state.c b/src/mesa/drivers/dri/i965/brw_wm_sampler_state.c
index 83a4b02e48..81fc9ef2f0 100644
--- a/src/mesa/drivers/dri/i965/brw_wm_sampler_state.c
+++ b/src/mesa/drivers/dri/i965/brw_wm_sampler_state.c
@@ -192,8 +192,8 @@ static void brw_update_sampler_state( struct gl_texture_unit *texUnit,
*/
sampler->ss0.base_level = U_FIXED(0, 1);
- sampler->ss1.max_lod = U_FIXED(MAX2(texObj->MaxLod, 0), 6);
- sampler->ss1.min_lod = U_FIXED(MAX2(texObj->MinLod, 0), 6);
+ sampler->ss1.max_lod = U_FIXED(MIN2(MAX2(texObj->MaxLod, 0), 13), 6);
+ sampler->ss1.min_lod = U_FIXED(MIN2(MAX2(texObj->MinLod, 0), 13), 6);
sampler->ss2.default_color_pointer = sdc_gs_offset >> 5;
}