1
0
mirror of https://github.com/DigvijaysinhGohil/Godot-Shader-Lib.git synced 2025-01-09 18:58:45 +08:00
2024-03-26 10:20:51 +05:30

7 lines
272 B
Plaintext

float gyroid_noise(vec2 uv, float scale, vec2 ratio, float height, float thickness) {
scale *= 10.;
thickness = clamp(thickness, 0., 1.);
vec3 vector = vec3(uv, height);
vector *= scale;
return abs(dot(sin(vector * ratio.x), cos(vector.zxy * ratio.y))) - thickness;
}