[Mesa-dev] [PATCH RFC 01/11] glsl: fix handling of quadop_vector constant expression

Connor Abbott cwabbott0 at gmail.com
Wed Jan 22 09:16:48 PST 2014


We forgot to handle the case where the base type was a boolean.
---
 src/glsl/ir_constant_expression.cpp | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/glsl/ir_constant_expression.cpp b/src/glsl/ir_constant_expression.cpp
index f811fd1..9edc378 100644
--- a/src/glsl/ir_constant_expression.cpp
+++ b/src/glsl/ir_constant_expression.cpp
@@ -1501,6 +1501,9 @@ ir_expression::constant_expression_value(struct hash_table *variable_context)
 	 case GLSL_TYPE_FLOAT:
 	    data.f[c] = op[c]->value.f[0];
 	    break;
+	 case GLSL_TYPE_BOOL:
+	    data.b[c] = op[c]->value.b[0];
+	    break;
 	 default:
 	    assert(0);
 	 }
-- 
1.8.3.1



More information about the mesa-dev mailing list