diff options
| author | Ryan Houdek <Sonicadvance1@gmail.com> | 2013-11-13 16:17:42 -0600 |
|---|---|---|
| committer | Ryan Houdek <Sonicadvance1@gmail.com> | 2013-11-13 16:17:42 -0600 |
| commit | 2a23bdde6f76c0bff0906bbbee298480b52ba0c2 (patch) | |
| tree | 22a7bccfb1cb25d4c9f247ca3d43904a4a6d79dc /Source/Core/VideoBackends/Software/Src/TransformUnit.cpp | |
| parent | 3c7613fc83981f9ef8efa2e4ac478af9fe23bdec (diff) | |
| parent | 63a9dff3bb8c88cdc5b941db1f3813843c7a8564 (diff) | |
Merge branch 'master' into android-new-control-input-overlay
Conflicts:
Source/Core/DolphinWX/Src/Android/ButtonManager.h
Diffstat (limited to 'Source/Core/VideoBackends/Software/Src/TransformUnit.cpp')
| -rw-r--r-- | Source/Core/VideoBackends/Software/Src/TransformUnit.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/Core/VideoBackends/Software/Src/TransformUnit.cpp b/Source/Core/VideoBackends/Software/Src/TransformUnit.cpp index a1c2bd190a..e00f05e4aa 100644 --- a/Source/Core/VideoBackends/Software/Src/TransformUnit.cpp +++ b/Source/Core/VideoBackends/Software/Src/TransformUnit.cpp @@ -248,7 +248,7 @@ void LightColor(const Vec3 &pos, const Vec3 &normal, u8 lightNum, const LitChann float attn; if (chan.attnfunc == 3) // spot - { + { float dist2 = ldir.length2(); float dist = sqrtf(dist2); ldir = ldir / dist; @@ -259,7 +259,7 @@ void LightColor(const Vec3 &pos, const Vec3 &normal, u8 lightNum, const LitChann attn = SafeDivide(max(0.0f, cosAtt), distAtt); } else if (chan.attnfunc == 1) // specular - { + { // donko - what is going on here? 655.36 is a guess but seems about right. attn = (light->pos * normal) > -655.36 ? max(0.0f, (light->dir * normal)) : 0; ldir.set(1.0f, attn, attn * attn); |
