Reset the shader to fix the minimap

This commit is contained in:
samuncle 2019-03-11 21:41:49 +01:00
parent bc49620b23
commit 5633d217a6
2 changed files with 2 additions and 4 deletions

View File

@ -28,12 +28,11 @@ void main()
vec3 SpecularComponent = texture(specular_map, tc).xyz;
vec3 diffuse_color_for_mix = diffuseMatColor.xyz * 4.0;
vec3 metallicMatColor = mix(vec3(0.5), diffuse_color_for_mix, metallicMapValue);
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 * emitMapValue * emitMapValue * 10.0);
vec4 color_1 = vec4(tmp * ao + (emitMapValue * emitCol), 1.0);
//color_1 = vec4(tmp, 1.);
// Fog
float depth = texture(depth_stencil, tc).x;
@ -59,5 +58,5 @@ void main()
color_2.g = ls.g + color_1.g * (1.0 - ls.a);
color_2.b = ls.b + color_1.b * (1.0 - ls.a);
color_2.a = ls.a + color_1.a * (1.0 - ls.a);
o_final_color = vec4(color_2.rgb, 1.0);
o_final_color = color_2;
}

View File

@ -39,7 +39,6 @@ void main(void)
o_normal_color.xy = 0.5 * EncodeNormal(normalize(normal)) + 0.5;
o_normal_color.zw = layer_2.xy;
o_normal_color.z = 0.5;
#else
o_diffuse_color = vec4(final_color, 1.0);
#endif