From d52dce0ffbb165146d7b6812ff5152cbeff29a3a Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jos=C3=A9=20Fonseca?= Date: Fri, 7 Aug 2009 09:28:58 +0100 Subject: [PATCH] llvmpipe: Fix floating point const scale factor. --- src/gallium/drivers/llvmpipe/lp_bld_const.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/llvmpipe/lp_bld_const.c b/src/gallium/drivers/llvmpipe/lp_bld_const.c index d36a6102342..73dc9678de8 100644 --- a/src/gallium/drivers/llvmpipe/lp_bld_const.c +++ b/src/gallium/drivers/llvmpipe/lp_bld_const.c @@ -48,7 +48,9 @@ unsigned lp_const_shift(union lp_type type) { - if(type.fixed) + if(type.floating) + return 0; + else if(type.fixed) return type.width/2; else if(type.norm) return type.sign ? type.width - 1 : type.width; -- 2.30.2