From 713ff9619daa858ffbd428f7699cd57598563dbd Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Sat, 13 Mar 2021 16:00:36 +0200 Subject: [PATCH] Fix some errors in the shader library --- shaderlib/common.glsl | 2 +- shaderlib/msp_interface.glsl | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/shaderlib/common.glsl b/shaderlib/common.glsl index bac82fc1..eb191e45 100644 --- a/shaderlib/common.glsl +++ b/shaderlib/common.glsl @@ -89,5 +89,5 @@ vec3 get_reflection(vec3 normal, vec3 look) vec3 apply_fog(vec3 color) { float fog_value = exp(fog_coord*fog_density); - return mix(fog_color, color, fog_value); + return mix(fog_color.rgb, color, fog_value); } diff --git a/shaderlib/msp_interface.glsl b/shaderlib/msp_interface.glsl index ba6f3178..1c3029ef 100644 --- a/shaderlib/msp_interface.glsl +++ b/shaderlib/msp_interface.glsl @@ -60,6 +60,7 @@ uniform Lighting uniform sampler2D diffuse_map; uniform sampler2D specular_map; uniform sampler2D shininess_map; +uniform sampler2D reflectivity_map; uniform sampler2D base_color_map; uniform sampler2D metalness_map; uniform sampler2D roughness_map; @@ -80,7 +81,7 @@ uniform EnvMap mat3 env_eye_matrix; }; -const int max_clip_planes = 0; +layout(constant_id=auto) const int max_clip_planes = 0; uniform Clipping { ClipPlane clip_planes[max_clip_planes]; -- 2.45.2