Skip to content

Commit 9db792c

Browse files
committed
Fixed #11421
1 parent 8900967 commit 9db792c

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

core/assets/shaders/slag.frag

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ void main(){
1818
vec2 coords = v_texCoords * u_resolution + u_campos;
1919

2020
float btime = u_time / 5000.0;
21+
vec4 orig = texture2D(u_texture, v_texCoords);
2122
float noise = (texture2D(u_noise, (coords) / NSCALE + vec2(btime) * vec2(-0.9, 0.8)).r + texture2D(u_noise, (coords) / NSCALE + vec2(btime * 1.1) * vec2(0.8, -1.0)).r) / 2.0;
2223

2324
//TODO: pack noise texture
@@ -27,6 +28,9 @@ void main(){
2728
) - vec2(0.5)) * 8.0 / u_resolution;
2829

2930
vec4 color = texture2D(u_texture, c);
31+
if(color.a < 0.95){
32+
color = orig;
33+
}
3034

3135
if(noise > 0.6){
3236
color.rgb = S2;

0 commit comments

Comments
 (0)