Parcourir la source

do not modulate emissive by diffuseColor.

Ben Houston il y a 10 ans
Parent
commit
728f409415
1 fichiers modifiés avec 2 ajouts et 2 suppressions
  1. 2 2
      src/renderers/shaders/ShaderChunk/lights_phong_fragment.glsl

+ 2 - 2
src/renderers/shaders/ShaderChunk/lights_phong_fragment.glsl

@@ -229,10 +229,10 @@ vec3 totalSpecularLight = vec3( 0.0 );
 
 #ifdef METAL
 
-	outgoingLight += diffuseColor.rgb * ( emissive + totalDiffuseLight + ambientLightColor * ambient + totalSpecularLight );
+	outgoingLight += diffuseColor.rgb * ( totalDiffuseLight + ambientLightColor * ambient + totalSpecularLight ) + emissive;
 
 #else
 
-	outgoingLight += diffuseColor.rgb * ( emissive + totalDiffuseLight + ambientLightColor * ambient ) + totalSpecularLight;
+	outgoingLight += diffuseColor.rgb * ( totalDiffuseLight + ambientLightColor * ambient ) + totalSpecularLight + emissive;
 
 #endif