mirror of
https://github.com/OpenMW/openmw.git
synced 2025-01-30 21:45:36 +00:00
Merge branch 'AnyOldName3-spec-power' into 'master'
Actually use specular shininess parameter instead of hardcoded value. See merge request OpenMW/openmw!85
This commit is contained in:
commit
0ab0e6ef93
2 changed files with 2 additions and 1 deletions
|
@ -41,6 +41,7 @@
|
|||
Bug #4877: Startup script executes only on a new game start
|
||||
Bug #4888: Global variable stray explicit reference calls break script compilation
|
||||
Bug #4911: Editor: QOpenGLContext::swapBuffers() warning with Qt5
|
||||
Bug #4916: Specular power (shininess) material parameter is ignored when shaders are used.
|
||||
Feature #2229: Improve pathfinding AI
|
||||
Feature #3442: Default values for fallbacks from ini file
|
||||
Feature #3610: Option to invert X axis
|
||||
|
|
|
@ -78,5 +78,5 @@ vec3 getSpecular(vec3 viewNormal, vec3 viewDirection, float shininess, vec3 matS
|
|||
if (NdotL < 0.0)
|
||||
return vec3(0.,0.,0.);
|
||||
vec3 halfVec = normalize(lightDir - viewDirection);
|
||||
return pow(max(dot(viewNormal, halfVec), 0.0), 128.) * gl_LightSource[0].specular.xyz * matSpec;
|
||||
return pow(max(dot(viewNormal, halfVec), 0.0), shininess) * gl_LightSource[0].specular.xyz * matSpec;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue