From e0d828b22e9b18a7ca79f991d5dd4ae989e2817b Mon Sep 17 00:00:00 2001 From: milek7 Date: Thu, 19 Sep 2019 18:43:19 +0200 Subject: [PATCH] smoke fog fix --- shaders/smoke.frag | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/shaders/smoke.frag b/shaders/smoke.frag index aa9a8c2d..21885aa3 100644 --- a/shaders/smoke.frag +++ b/shaders/smoke.frag @@ -17,11 +17,11 @@ layout(location = 1) out vec4 out_motion; void main() { - vec4 tex_color = texture(tex1, f_coord); + vec4 tex_color = texture(tex1, f_coord) * f_color; #if POSTFX_ENABLED - out_color = tex_color * f_color; + out_color = vec4(apply_fog(tex_color.rgb), tex_color.a); #else - out_color = tonemap(tex_color * f_color); + out_color = tonemap(vec4(apply_fog(tex_color.rgb), tex_color.a)); #endif #if MOTIONBLUR_ENABLED {