static const glsl_type *const mat4x3_type;
static const glsl_type *const mat4_type;
/*@}*/
-
- /**
- * Get the built-in instance of the vec4 type for a specific base type
- */
- static const glsl_type *get_vec4_type(glsl_base_type base_type)
- {
- if (base_type == GLSL_TYPE_FLOAT)
- return vec4_type;
- else if (base_type == GLSL_TYPE_INT)
- return ivec4_type;
- else if (base_type == GLSL_TYPE_UINT)
- return uvec4_type;
- else
- return NULL;
- }
/**
if (ir->operands[0]->type->is_vector() ||
ir->operands[1]->type->is_vector()) {
st_src_reg temp = get_temp(glsl_version >= 130 ?
- glsl_type::get_vec4_type(ir->operands[0]->type->base_type) :
+ glsl_type::get_instance(ir->operands[0]->type->base_type, 4, 1) :
glsl_type::vec4_type);
assert(ir->operands[0]->type->base_type == GLSL_TYPE_FLOAT);
emit(ir, TGSI_OPCODE_SNE, st_dst_reg(temp), op[0], op[1]);
if (ir->operands[0]->type->is_vector() ||
ir->operands[1]->type->is_vector()) {
st_src_reg temp = get_temp(glsl_version >= 130 ?
- glsl_type::get_vec4_type(ir->operands[0]->type->base_type) :
+ glsl_type::get_instance(ir->operands[0]->type->base_type, 4, 1) :
glsl_type::vec4_type);
assert(ir->operands[0]->type->base_type == GLSL_TYPE_FLOAT);
emit(ir, TGSI_OPCODE_SNE, st_dst_reg(temp), op[0], op[1]);