diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2021-02-21 02:46:41 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2021-02-21 03:33:56 +0300 |
commit | 1d51cb6be24e3097de2a20f490ef0dd535240f5b (patch) | |
tree | edf300e8c8100db887ae582e7a9c59b63ca96899 /source/blender/gpu/shaders/material/gpu_shader_material_glossy.glsl | |
parent | dee94afd039de7b7d3002ff2f8f1f0bf4c515bb3 (diff) |
Cleanup: EEVEE: change cameraVec macro to cameraVec(P)
This makes is clearer and avoid having to setup worldPosition if
shader is not a material shader.
Diffstat (limited to 'source/blender/gpu/shaders/material/gpu_shader_material_glossy.glsl')
-rw-r--r-- | source/blender/gpu/shaders/material/gpu_shader_material_glossy.glsl | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/gpu/shaders/material/gpu_shader_material_glossy.glsl b/source/blender/gpu/shaders/material/gpu_shader_material_glossy.glsl index ca7c3749597..fa83bfb6c7a 100644 --- a/source/blender/gpu/shaders/material/gpu_shader_material_glossy.glsl +++ b/source/blender/gpu/shaders/material/gpu_shader_material_glossy.glsl @@ -16,7 +16,7 @@ void node_bsdf_glossy( result = CLOSURE_DEFAULT; - vec2 split_sum = brdf_lut(dot(in_Glossy_0.N, cameraVec), in_Glossy_0.roughness); + vec2 split_sum = brdf_lut(dot(in_Glossy_0.N, cameraVec(worldPosition)), in_Glossy_0.roughness); vec3 brdf = (use_multiscatter != 0.0) ? F_brdf_multi_scatter(vec3(1.0), vec3(1.0), split_sum) : F_brdf_single_scatter(vec3(1.0), vec3(1.0), split_sum); out_Glossy_0.radiance = closure_mask_ssr_radiance(out_Glossy_0.radiance, ssr_id); |