Fixes issues in e.g. nexuiz (desertfactory) or supertuxkart that
look like lighting bugs.
They're not visible with the software rasterizers because their
notion of linear interpolation seems to be different from that
of nv50/nvc0.
if (i->opcode == NV_OP_PINTERP) {
pc->emit[0] |= 0x040;
SID(pc, i->src[1], 26);
+
+ if (i->src[0]->value->reg.address >= 0x280 &&
+ i->src[0]->value->reg.address <= 0x29c)
+ pc->emit[0] |= 0x080; /* XXX: ? */
} else {
SID(pc, NULL, 26);
}
else
if (decl->Declaration.Interpolate == TGSI_INTERPOLATE_PERSPECTIVE)
mode = NVC0_INTERP_PERSPECTIVE;
+ else
+ if (decl->Declaration.Semantic && decl->Semantic.Name == TGSI_SEMANTIC_COLOR)
+ mode = NVC0_INTERP_PERSPECTIVE;
else
mode = NVC0_INTERP_LINEAR;