Browse Source

Fix a bug

Panagiotis Christopoulos Charitos 5 years ago
parent
commit
b5923a1ea4
1 changed files with 1 additions and 1 deletions
  1. 1 1
      shaders/Ssgi.ankiprog

+ 1 - 1
shaders/Ssgi.ankiprog

@@ -110,7 +110,7 @@ void main()
 		outColor = Vec4(0.0, 0.0, 0.0, 1.0);
 		outColor = Vec4(0.0, 0.0, 0.0, 1.0);
 	}
 	}
 
 
-	const F32 NoL = saturate(dot(randomHemisphere, worldNormal));
+	const F32 NoL = max(0.0, dot(randomHemisphere, viewNormal));
 	outColor.xyz *= NoL;
 	outColor.xyz *= NoL;
 
 
 	imageStore(out_img, fixedInvocationId, outColor);
 	imageStore(out_img, fixedInvocationId, outColor);