mirror of
https://github.com/godotengine/godot.git
synced 2025-11-04 23:51:24 +00:00
Merge pull request #56844 from Calinou/ssr-fix-background-line-master
Fix visible background line in intersections in screen-space reflections
This commit is contained in:
commit
3ae38edc8e
1 changed files with 1 additions and 2 deletions
|
|
@ -190,8 +190,7 @@ void main() {
|
||||||
}
|
}
|
||||||
|
|
||||||
vec2 final_pos;
|
vec2 final_pos;
|
||||||
float grad;
|
float grad = (steps_taken + 1.0) / float(params.num_steps);
|
||||||
grad = steps_taken / float(params.num_steps);
|
|
||||||
float initial_fade = params.curve_fade_in == 0.0 ? 1.0 : pow(clamp(grad, 0.0, 1.0), params.curve_fade_in);
|
float initial_fade = params.curve_fade_in == 0.0 ? 1.0 : pow(clamp(grad, 0.0, 1.0), params.curve_fade_in);
|
||||||
float fade = pow(clamp(1.0 - grad, 0.0, 1.0), params.distance_fade) * initial_fade;
|
float fade = pow(clamp(1.0 - grad, 0.0, 1.0), params.distance_fade) * initial_fade;
|
||||||
final_pos = pos;
|
final_pos = pos;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue