From 23e9b43ce4a6ad5875f69363dec7d2baa8afa2ea Mon Sep 17 00:00:00 2001 From: Nicolai Haehnle Date: Mon, 30 Jun 2008 08:37:13 +0200 Subject: [PATCH] r300: Fix dumb mistake in LOD bias translation --- src/mesa/drivers/dri/r300/r300_state.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/r300/r300_state.c b/src/mesa/drivers/dri/r300/r300_state.c index 9e4cc777a98..f6f0c390662 100644 --- a/src/mesa/drivers/dri/r300/r300_state.c +++ b/src/mesa/drivers/dri/r300/r300_state.c @@ -1388,7 +1388,7 @@ static GLuint translate_lod_bias(GLfloat bias) b = (1 << 9)-1; else if (b < -(1 << 9)) b = -(1 << 9); - return ((GLuint)b) << R300_LOD_BIAS_SHIFT; + return (((GLuint)b) << R300_LOD_BIAS_SHIFT) & R300_LOD_BIAS_MASK; } static void r300SetupTextures(GLcontext * ctx) -- 2.30.2