diff options
Diffstat (limited to 'source/blender/gpu/shaders/material/gpu_shader_material_eevee_specular.glsl')
-rw-r--r-- | source/blender/gpu/shaders/material/gpu_shader_material_eevee_specular.glsl | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/gpu/shaders/material/gpu_shader_material_eevee_specular.glsl b/source/blender/gpu/shaders/material/gpu_shader_material_eevee_specular.glsl index d5623c890e4..0941482df45 100644 --- a/source/blender/gpu/shaders/material/gpu_shader_material_eevee_specular.glsl +++ b/source/blender/gpu/shaders/material/gpu_shader_material_eevee_specular.glsl @@ -38,7 +38,7 @@ void node_eevee_specular(vec4 diffuse, /* Diffuse. */ out_Diffuse_0.radiance = render_pass_diffuse_mask(vec3(1), out_Diffuse_0.radiance); out_Diffuse_0.radiance *= in_Diffuse_0.albedo; - result += out_Diffuse_0.radiance; + result.radiance += out_Diffuse_0.radiance; } { /* Glossy. */ @@ -48,7 +48,7 @@ void node_eevee_specular(vec4 diffuse, out_Glossy_1.radiance = closure_mask_ssr_radiance(out_Glossy_1.radiance, ssr_id); out_Glossy_1.radiance *= brdf; - out_Glossy_1.radiance = render_pass_glossy_mask(spec_color, out_Glossy_1.radiance); + out_Glossy_1.radiance = render_pass_glossy_mask(specular.rgb, out_Glossy_1.radiance); closure_load_ssr_data( out_Glossy_1.radiance, in_Glossy_1.roughness, in_Glossy_1.N, ssr_id, result); } @@ -64,12 +64,12 @@ void node_eevee_specular(vec4 diffuse, } { /* Emission. */ - vec3 out_emission_radiance = render_pass_emission_mask(emission.rgb); + vec3 out_emission_radiance = render_pass_emission_mask(emissive.rgb); result.radiance += out_emission_radiance; } - float trans = 1.0 - trans; - result.transmittance = vec3(trans); + float alpha = 1.0 - transp; + result.transmittance = vec3(transp); result.radiance *= alpha; result.ssr_data.rgb *= alpha; } |