Mesa (master): st/mesa: Apply LOD from texture object

Brian Paul brianp at kemper.freedesktop.org
Tue Apr 5 08:09:54 PDT 2011


Module: Mesa
Branch: master
Commit: 5d5db24a26415cdec4b3d3f2a92bae7112c9f884
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=5d5db24a26415cdec4b3d3f2a92bae7112c9f884

Author: Fabian Bieler <der.fabe at gmx.net>
Date:   Fri Mar 25 11:06:01 2011 +0100

st/mesa: Apply LOD from texture object

Signed-off-by: Brian Paul <brianp at vmware.com>

---

 src/mesa/state_tracker/st_atom_sampler.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/src/mesa/state_tracker/st_atom_sampler.c b/src/mesa/state_tracker/st_atom_sampler.c
index 96bdc7f..5f1849d 100644
--- a/src/mesa/state_tracker/st_atom_sampler.c
+++ b/src/mesa/state_tracker/st_atom_sampler.c
@@ -163,7 +163,8 @@ update_samplers(struct st_context *st)
          if (texobj->Target != GL_TEXTURE_RECTANGLE_ARB)
             sampler->normalized_coords = 1;
 
-         sampler->lod_bias = st->ctx->Texture.Unit[texUnit].LodBias;
+         sampler->lod_bias = st->ctx->Texture.Unit[texUnit].LodBias +
+            texobj->LodBias;
 
          sampler->min_lod = texobj->BaseLevel + texobj->MinLod;
          if (sampler->min_lod < texobj->BaseLevel)



More information about the mesa-commit mailing list