ir_to_mesa: Fix the indexing of attributes in the program's Attributes.
This fixes GetAttribLocation returning VERT_ATTRIB_GENERIC1 instead of 1, caught by glsl-dlist-getattriblocation.
This commit is contained in:
@@ -1008,7 +1008,7 @@ ir_to_mesa_visitor::visit(ir_dereference_variable *ir)
|
|||||||
ir->var->name,
|
ir->var->name,
|
||||||
type_size(ir->var->type) * 4,
|
type_size(ir->var->type) * 4,
|
||||||
ir->var->type->gl_type,
|
ir->var->type->gl_type,
|
||||||
ir->var->location);
|
ir->var->location - VERT_ATTRIB_GENERIC0);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
entry = new(mem_ctx) temp_entry(ir->var,
|
entry = new(mem_ctx) temp_entry(ir->var,
|
||||||
|
Reference in New Issue
Block a user