protot/data/shaders/fs_simpletexture.glsl

19 lines
261 B
Plaintext
Raw Normal View History

2018-02-13 14:27:16 +01:00
#version 330 core
in vec2 ioUV;
2018-02-13 14:27:16 +01:00
out vec3 outColor;
2018-02-13 14:27:16 +01:00
uniform sampler2D uTexture;
uniform float uTime;
2018-02-13 14:27:16 +01:00
void main() {
2018-02-16 21:22:34 +01:00
outColor = texture(uTexture,
ioUV
+ 0.01 * vec2(
sin(uTime + 1024.0 * ioUV.x),
cos(uTime + 768.0 * ioUV.y)
)
).xyz;
2018-02-13 14:27:16 +01:00
}