You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
434 B
GLSL
22 lines
434 B
GLSL
10 years ago
|
// Author @patriciogv - 2015
|
||
|
// http://patriciogonzalezvivo.com
|
||
|
#ifdef GL_ES
|
||
|
precision mediump float;
|
||
|
#endif
|
||
|
|
||
|
uniform vec2 u_resolution;
|
||
|
uniform float u_time;
|
||
|
|
||
|
float random (in vec2 _st) {
|
||
|
return fract(sin(dot(_st.xy,
|
||
|
vec2(12.9898,78.233)))*
|
||
|
43758.5453123);
|
||
|
}
|
||
|
|
||
|
void main() {
|
||
|
vec2 st = gl_FragCoord.xy/u_resolution.xy;
|
||
|
|
||
|
float rnd = random( st );
|
||
|
|
||
|
gl_FragColor = vec4(vec3(rnd),1.0);
|
||
|
}
|