PixelShaderGen: Change the "colors" and "kcolors" uniforms to be integers.

This commit is contained in:
Tony Wasserka
2013-10-10 20:26:41 +02:00
parent df94e62350
commit ec60acac3a
3 changed files with 47 additions and 47 deletions

View File

@ -152,14 +152,14 @@ void PixelShaderManager::SetConstants()
// TODO: Conversion should be checked in the context of tev_fixes..
void PixelShaderManager::SetColorChanged(int type, int num)
{
float4* c = type ? constants.kcolors : constants.colors;
c[num][0] = bpmem.tevregs[num].low.a / 255.0f;
c[num][3] = bpmem.tevregs[num].low.b / 255.0f;
c[num][2] = bpmem.tevregs[num].high.a / 255.0f;
c[num][1] = bpmem.tevregs[num].high.b / 255.0f;
int4* c = type ? constants.kcolors : constants.colors;
c[num][0] = bpmem.tevregs[num].low.a;
c[num][3] = bpmem.tevregs[num].low.b;
c[num][2] = bpmem.tevregs[num].high.a;
c[num][1] = bpmem.tevregs[num].high.b;
dirty = true;
PRIM_LOG("pixel %scolor%d: %f %f %f %f\n", type?"k":"", num, c[num][0], c[num][1], c[num][2], c[num][3]);
PRIM_LOG("pixel %scolor%d: %d %d %d %d\n", type?"k":"", num, c[num][0], c[num][1], c[num][2], c[num][3]);
}
void PixelShaderManager::SetAlpha()