[Mesa-dev] [PATCH 2/4] st/mesa: use UniformBooleanTrue in glsl_to_tgsi
Marek Olšák
maraeo at gmail.com
Fri Sep 19 12:08:34 PDT 2014
From: Marek Olšák <marek.olsak at amd.com>
Just for consistency. This doesn't fix anything as the original code was
already pretty good.
---
src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
index b338a98..57f43a6 100644
--- a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
+++ b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
@@ -2617,10 +2617,7 @@ glsl_to_tgsi_visitor::visit(ir_constant *ir)
case GLSL_TYPE_BOOL:
gl_type = native_integers ? GL_BOOL : GL_FLOAT;
for (i = 0; i < ir->type->vector_elements; i++) {
- if (native_integers)
- values[i].u = ir->value.b[i] ? ~0 : 0;
- else
- values[i].f = ir->value.b[i];
+ values[i].u = ir->value.b[i] ? ctx->Const.UniformBooleanTrue : 0;
}
break;
default:
--
1.9.1
More information about the mesa-dev
mailing list