瀏覽代碼

Fixed shader compile error for PlayBook.

Darryl Gough 14 年之前
父節點
當前提交
9ed865709e
共有 2 個文件被更改,包括 0 次插入4 次删除
  1. 0 2
      gameplay/res/shaders/colored.fsh
  2. 0 2
      gameplay/res/shaders/diffuse.fsh

+ 0 - 2
gameplay/res/shaders/colored.fsh

@@ -22,8 +22,6 @@ void lighting(vec3 normalVector, vec3 lightDirection, float attenuation)
 
 
     // Diffuse
     // Diffuse
 	float ddot = dot(normalVector, lightDirection);
 	float ddot = dot(normalVector, lightDirection);
-	if (ddot < 0)
-		ddot = abs(ddot) * 0.5f; // simulate light bounce at half intensity
     float diffuseIntensity = attenuation * ddot;
     float diffuseIntensity = attenuation * ddot;
     diffuseIntensity = max(0.0, diffuseIntensity);
     diffuseIntensity = max(0.0, diffuseIntensity);
     _diffuseColor = u_lightColor * _baseColor.rgb * diffuseIntensity;
     _diffuseColor = u_lightColor * _baseColor.rgb * diffuseIntensity;

+ 0 - 2
gameplay/res/shaders/diffuse.fsh

@@ -23,8 +23,6 @@ void lighting(vec3 normalVector, vec3 lightDirection, float attenuation)
 
 
     // Diffuse
     // Diffuse
 	float ddot = dot(normalVector, lightDirection);
 	float ddot = dot(normalVector, lightDirection);
-	if (ddot < 0)
-		ddot = abs(ddot) * 0.5f; // simulate light bounce at half intensity
     float diffuseIntensity = attenuation * ddot;
     float diffuseIntensity = attenuation * ddot;
     diffuseIntensity = max(0.0, diffuseIntensity);
     diffuseIntensity = max(0.0, diffuseIntensity);
     _diffuseColor = u_lightColor * _baseColor.rgb * diffuseIntensity;
     _diffuseColor = u_lightColor * _baseColor.rgb * diffuseIntensity;