mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 13:10:10 +01:00
i965/vs: Fix abs/negate handling on attributes.
Fixes glsl-vs-neg-attribute and glsl-vs-abs-attribute.
This commit is contained in:
parent
7642c1de6b
commit
54e66a0a63
1 changed files with 9 additions and 2 deletions
|
|
@ -65,9 +65,16 @@ vec4_visitor::setup_attributes(int payload_reg)
|
|||
continue;
|
||||
|
||||
int grf = attribute_map[inst->src[i].reg + inst->src[i].reg_offset];
|
||||
|
||||
struct brw_reg reg = brw_vec8_grf(grf, 0);
|
||||
reg.dw1.bits.swizzle = inst->src[i].swizzle;
|
||||
if (inst->src[i].abs)
|
||||
reg = brw_abs(reg);
|
||||
if (inst->src[i].negate)
|
||||
reg = negate(reg);
|
||||
|
||||
inst->src[i].file = HW_REG;
|
||||
inst->src[i].fixed_hw_reg = brw_vec8_grf(grf, 0);
|
||||
inst->src[i].fixed_hw_reg.dw1.bits.swizzle = inst->src[i].swizzle;
|
||||
inst->src[i].fixed_hw_reg = reg;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue