1
Fork 0
mirror of https://github.com/Steffo99/pineapple-surf.git synced 2024-11-24 08:44:18 +00:00
pineapple-surf/island/sinking/Sea.gdshader

14 lines
340 B
Text

shader_type spatial;
uniform float speed_x;
uniform float speed_y;
uniform float size;
uniform sampler2D sea: filter_nearest;
void fragment() {
float x = fract(UV.x * size + sin(TIME) * speed_x);
float y = fract(UV.y * size - TIME * 2.0 * speed_y);
vec4 color = texture(sea, vec2(x, y));
ALBEDO = vec3(color.r, color.g, color.b);
}