mirror of
https://github.com/PabloMK7/citra.git
synced 2025-12-18 21:28:46 +00:00
glsl_shader_fs_gen: Apply shadow before ambient light (#7404)
This commit is contained in:
parent
63feac6bb3
commit
480604ec72
2 changed files with 15 additions and 14 deletions
|
|
@ -810,8 +810,8 @@ void FragmentModule::WriteLighting() {
|
|||
|
||||
// Compute primary fragment color (diffuse lighting) function
|
||||
out += fmt::format(
|
||||
"diffuse_sum.rgb += (({}.diffuse * dot_product) + {}.ambient) * {} * {}{};\n",
|
||||
light_src, light_src, dist_atten, spot_atten, shadow_primary);
|
||||
"diffuse_sum.rgb += (({}.diffuse * dot_product{}) + {}.ambient) * {} * {};\n",
|
||||
light_src, shadow_primary, light_src, dist_atten, spot_atten);
|
||||
|
||||
// Compute secondary fragment color (specular lighting) function
|
||||
out += fmt::format("specular_sum.rgb += ({} + {}) * clamp_highlights * {} * {}{};\n",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue