diff options
author | Samuel Pitoiset <[email protected]> | 2017-04-21 11:18:50 +0200 |
---|---|---|
committer | Samuel Pitoiset <[email protected]> | 2017-04-21 19:34:15 +0200 |
commit | a7bc51aef8ef7e3374e034bfbe33096e985ffb0b (patch) | |
tree | d37cd02757c0c56cf0928a871123b631be4a2017 /src/compiler/glsl/ir_expression_operation.py | |
parent | cacc823c39044307e6befe12c3f51317f09973e2 (diff) |
glsl: make use of glsl_type::is_float()
Signed-off-by: Samuel Pitoiset <[email protected]>
Reviewed-by: Samuel Iglesias Gonsálvez <[email protected]>
Reviewed-by: Edward O'Callaghan <[email protected]>
Diffstat (limited to 'src/compiler/glsl/ir_expression_operation.py')
-rw-r--r-- | src/compiler/glsl/ir_expression_operation.py | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/compiler/glsl/ir_expression_operation.py b/src/compiler/glsl/ir_expression_operation.py index d5e596b9179..fd9f103e96c 100644 --- a/src/compiler/glsl/ir_expression_operation.py +++ b/src/compiler/glsl/ir_expression_operation.py @@ -276,12 +276,9 @@ constant_template_vector = mako.template.Template("""\ # This template is for ir_triop_lrp. constant_template_lrp = mako.template.Template("""\ case ${op.get_enum_name()}: { - assert(op[0]->type->base_type == GLSL_TYPE_FLOAT || - op[0]->type->is_double()); - assert(op[1]->type->base_type == GLSL_TYPE_FLOAT || - op[1]->type->is_double()); - assert(op[2]->type->base_type == GLSL_TYPE_FLOAT || - op[2]->type->is_double()); + assert(op[0]->type->is_float() || op[0]->type->is_double()); + assert(op[1]->type->is_float() || op[1]->type->is_double()); + assert(op[2]->type->is_float() || op[2]->type->is_double()); unsigned c2_inc = op[2]->type->is_scalar() ? 0 : 1; for (unsigned c = 0, c2 = 0; c < components; c2 += c2_inc, c++) { |