From 0634b64ee4beaae0c6ee58d19b22aa334b6e6a69 Mon Sep 17 00:00:00 2001
From: Elohiem <20236-Elohiem@users.noreply.gitgud.io>
Date: Wed, 4 Jan 2023 10:08:20 +0100
Subject: [PATCH] Fix black pixels

---
 src/art/webgl/engine.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/art/webgl/engine.js b/src/art/webgl/engine.js
index ab77c0cc968..68e2789f40d 100644
--- a/src/art/webgl/engine.js
+++ b/src/art/webgl/engine.js
@@ -544,7 +544,7 @@ App.Art.Engine = class {
 
 						// kS is equal to Fresnel
 						vec3 kD = vec3(1.0) - F;
-						kD *= min(1.0 - metallic, 0.9999);	  
+						kD *= 1.0 - min(metallic, 0.9999);	  
 						
 						// add to outgoing radiance Lo
 						float NdotL = max(dot(N, L), 0.0);
@@ -593,7 +593,7 @@ App.Art.Engine = class {
 
 						// kS is equal to Fresnel
 						vec3 kD = vec3(1.0) - F;
-						kD *= min(1.0 - metallic, 0.9999);;
+						kD *= 1.0 - min(metallic, 0.9999);
 				
 						// add to outgoing radiance Lo
 						float NdotL = max(dot(N, L), 0.0);
-- 
GitLab