diff --git a/data/shaders/combine_diffuse_color.frag b/data/shaders/combine_diffuse_color.frag index f2dee049c..df7f34e86 100644 --- a/data/shaders/combine_diffuse_color.frag +++ b/data/shaders/combine_diffuse_color.frag @@ -23,7 +23,8 @@ void main() vec3 DiffuseComponent = texture(diffuse_map, tc).xyz; vec3 SpecularComponent = texture(specular_map, tc).xyz; - vec3 metallicMatColor = mix(vec3(0.04), diffuseMatColor.xyz * 4, metallicMapValue); + vec3 diffuse_color_for_mix = diffuseMatColor.xyz * 4.0; + vec3 metallicMatColor = mix(vec3(0.04), diffuse_color_for_mix, metallicMapValue); vec3 tmp = DiffuseComponent * mix(diffuseMatColor.xyz, vec3(0.0), metallicMapValue) + (metallicMatColor * SpecularComponent); vec3 emitCol = diffuseMatColor.xyz * diffuseMatColor.xyz * diffuseMatColor.xyz * 15.;