Rework XF register loading a bit and change how registers are arranged in memory. This removes the assumption that all data for a viewport or projection matrix will be available when index 0 is loaded. Fixes issue 3688 and probably breaks old save states (sorry).

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7083 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
donkopunchstania
2011-02-05 18:25:34 +00:00
parent 98e24f5873
commit c36ed08cfc
10 changed files with 414 additions and 379 deletions

View File

@ -291,10 +291,10 @@ void GLVertexFormat::EnableComponents(u32 components)
// TODO - Is this a good spot for this code?
if (g_ActiveConfig.bDisableLighting)
{
for (int i = 0; i < xfregs.nNumChans; i++)
for (int i = 0; i < xfregs.numChan.numColorChans; i++)
{
xfregs.colChans[i].alpha.enablelighting = false;
xfregs.colChans[i].color.enablelighting = false;
xfregs.alpha[i].enablelighting = false;
xfregs.color[i].enablelighting = false;
}
}