mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 14:19:46 -06:00
long time no commits :).
fixed one of the last graphic problems in smg, now the glow in the plants and planets must be correct. the error was caused by a error in lighting calculations. so it must affect other games. please test and let me know the results. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6103 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
@ -260,18 +260,19 @@ const char *GenerateVertexShaderCode(u32 components, API_TYPE api_type)
|
||||
if (alpha.matsource) {// from vertex
|
||||
if (components & (VB_HAS_COL0<<j))
|
||||
WRITE(p, "mat.w = color%d.w;\n", j);
|
||||
else WRITE(p, "mat.w = 1;\n");
|
||||
else WRITE(p, "mat.w = 1.0f;\n");
|
||||
}
|
||||
else // from color
|
||||
WRITE(p, "mat.w = "I_MATERIALS".C%d.w;\n", j+2);
|
||||
}
|
||||
|
||||
if (alpha.enablelighting && alpha.ambsource != color.ambsource) {
|
||||
if (alpha.enablelighting)
|
||||
{
|
||||
if (alpha.ambsource) {// from vertex
|
||||
if (components & (VB_HAS_COL0<<j) )
|
||||
WRITE(p, "lacc.w = color%d.w;\n", j);
|
||||
else
|
||||
WRITE(p, "lacc.w = 0;\n");
|
||||
WRITE(p, "lacc.w = 0.0f;\n");
|
||||
}
|
||||
else // from color
|
||||
WRITE(p, "lacc.w = "I_MATERIALS".C%d.w;\n", j);
|
||||
|
Reference in New Issue
Block a user