return;
}
- if (index >= ctx->Const.VertexProgram.MaxAttribs) {
+ if (index >= ctx->Const.Program[MESA_SHADER_VERTEX].MaxAttribs) {
_mesa_error(ctx, GL_INVALID_VALUE, "glBindAttribLocation(index)");
return;
}
const ir_variable *const var = ((ir_instruction *) node)->as_variable();
if (var == NULL
- || var->mode != ir_var_shader_in
- || var->location == -1)
+ || var->data.mode != ir_var_shader_in
+ || var->data.location == -1)
continue;
if (current_index == desired_index) {
* attribute, or if an error occurs, -1 will be returned."
*/
if (var == NULL
- || var->mode != ir_var_shader_in
- || var->location == -1
- || var->location < VERT_ATTRIB_GENERIC0)
+ || var->data.mode != ir_var_shader_in
+ || var->data.location == -1
+ || var->data.location < VERT_ATTRIB_GENERIC0)
continue;
if (strcmp(var->name, name) == 0)
- return var->location - VERT_ATTRIB_GENERIC0;
+ return var->data.location - VERT_ATTRIB_GENERIC0;
}
return -1;
const ir_variable *const var = ((ir_instruction *) node)->as_variable();
if (var == NULL
- || var->mode != ir_var_shader_in
- || var->location == -1)
+ || var->data.mode != ir_var_shader_in
+ || var->data.location == -1)
continue;
i++;
const ir_variable *const var = ((ir_instruction *) node)->as_variable();
if (var == NULL
- || var->mode != ir_var_shader_in
- || var->location == -1)
+ || var->data.mode != ir_var_shader_in
+ || var->data.location == -1)
continue;
const size_t len = strlen(var->name);
* attribute, or if an error occurs, -1 will be returned."
*/
if (var == NULL
- || var->mode != ir_var_shader_out
- || var->location == -1
- || var->location < FRAG_RESULT_DATA0)
+ || var->data.mode != ir_var_shader_out
+ || var->data.location == -1
+ || var->data.location < FRAG_RESULT_DATA0)
continue;
if (strcmp(var->name, name) == 0)
- return var->index;
+ return var->data.index;
}
return -1;
* attribute, or if an error occurs, -1 will be returned."
*/
if (var == NULL
- || var->mode != ir_var_shader_out
- || var->location == -1
- || var->location < FRAG_RESULT_DATA0)
+ || var->data.mode != ir_var_shader_out
+ || var->data.location == -1
+ || var->data.location < FRAG_RESULT_DATA0)
continue;
if (strcmp(var->name, name) == 0)
- return var->location - FRAG_RESULT_DATA0;
+ return var->data.location - FRAG_RESULT_DATA0;
}
return -1;