mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-23 13:30:02 +00:00
Fix SW spotlight
This commit is contained in:
parent
2517be6cbf
commit
38231ca60a
@ -315,7 +315,7 @@ void Lighter::Light(float colorOut0[4], float colorOut1[4], const float colorIn[
|
||||
break;
|
||||
case GE_LIGHTTYPE_SPOT:
|
||||
lightDir = gstate_c.lightdir[l];
|
||||
angle = toLight.Normalize() * lightDir.Normalize();
|
||||
angle = toLight.Normalized() * lightDir.Normalized();
|
||||
if (angle >= gstate_c.lightangle[l])
|
||||
lightScale = clamp(1.0f / (gstate_c.lightatt[l][0] + gstate_c.lightatt[l][1]*distanceToLight + gstate_c.lightatt[l][2]*distanceToLight*distanceToLight), 0.0f, 1.0f) * powf(angle, gstate_c.lightspotCoef[l]);
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user