Happy thousandth commit Nazara

Updated copyright year (Yay, 515 file updated)
Regenerated global headers
Fixed some typo
Improved some shaders
-Blah blah blah-

Thank you all for supporting my project !
-Lynix


Former-commit-id: e4e741b318ba4f203da5ffd265bd5e516e7ffd7d
This commit is contained in:
Lynix
2014-01-12 20:16:21 +01:00
parent 9389e1ea05
commit c096756dab
515 changed files with 546 additions and 545 deletions

View File

@@ -52,7 +52,7 @@ void main()
vec3 diffuseColor = gVec0.xyz;
vec3 normal = DecodeNormal(gVec1);
vec3 specularColor = vec3(gVec0.w);
float specularMultiplier = gVec0.w;
float depth = ColorToFloat(gVec2.xyz);
float shininess = (gVec2.w == 0.0) ? 0.0 : exp2(gVec2.w*10.5);
@@ -67,7 +67,7 @@ void main()
vec3 lightDiffuse = lambert * Lights[0].color.rgb * Lights[0].factors.y;
// Specular
vec3 lightSpecular = vec3(0.0);
vec3 lightSpecular;
if (shininess > 0.0)
{
vec3 viewSpace = vec3(texCoord*2.0 - 1.0, depth*2.0 - 1.0);
@@ -81,10 +81,10 @@ void main()
float specularFactor = max(dot(reflection, eyeVec), 0.0);
specularFactor = pow(specularFactor, shininess);
lightSpecular = specularFactor * Lights[0].color.rgb;
lightSpecular = specularFactor * Lights[0].color.rgb * specularMultiplier;
}
lightSpecular *= specularColor;
else
lightSpecular = vec3(0.0);
vec3 fragmentColor = diffuseColor * (lightAmbient + lightDiffuse + lightSpecular);
RenderTarget0 = vec4(fragmentColor, 1.0);

File diff suppressed because one or more lines are too long

View File

@@ -40,10 +40,10 @@ vec3 DecodeNormal(in vec4 encodedNormal)
{
//return encodedNormal.xyz*2.0 - 1.0;
float a = encodedNormal.x * kPI;
vec2 scth = vec2(sin(a), cos(a));
vec2 scth = vec2(sin(a), cos(a));
vec2 scphi = vec2(sqrt(1.0 - encodedNormal.y*encodedNormal.y), encodedNormal.y);
return vec3(scth.y*scphi.x, scth.x*scphi.x, scphi.y);
vec2 scphi = vec2(sqrt(1.0 - encodedNormal.y*encodedNormal.y), encodedNormal.y);
return vec3(scth.y*scphi.x, scth.x*scphi.x, scphi.y);
}
void main()
@@ -58,7 +58,7 @@ void main()
vec3 diffuseColor = gVec0.xyz;
vec3 normal = DecodeNormal(gVec1);
vec3 specularColor = vec3(gVec0.w);
float specularMultiplier = gVec0.w;
float depth = ColorToFloat(gVec2.xyz);
float shininess = (gVec2.w == 0.0) ? 0.0 : exp2(gVec2.w*10.5);
@@ -91,7 +91,7 @@ void main()
vec3 lightDiffuse = att * lambert * Lights[0].color.rgb * Lights[0].factors.y;
// Specular
vec3 lightSpecular = vec3(0.0);
vec3 lightSpecular;
if (shininess > 0.0)
{
vec3 eyeVec = normalize(EyePosition - worldPos.xyz);
@@ -99,10 +99,10 @@ void main()
float specularFactor = max(dot(reflection, eyeVec), 0.0);
specularFactor = pow(specularFactor, shininess);
lightSpecular = att * specularFactor * Lights[0].color.rgb;
lightSpecular = att * specularFactor * Lights[0].color.rgb * specularMultiplier;
}
lightSpecular *= specularColor;
else
lightSpecular = vec3(0.0);
vec3 fragmentColor = diffuseColor * (lightAmbient + lightDiffuse + lightSpecular);
RenderTarget0 = vec4(fragmentColor, 1.0);

File diff suppressed because one or more lines are too long