glsl-util/random.glsl

5 lines
123 B
Plaintext
Raw Normal View History

2017-01-30 14:48:34 +08:00
float random(vec2 c){
return fract(sin(dot(c.xy ,vec2(12.9898,78.233))) * 43758.5453);
2016-12-27 00:19:28 +08:00
}
#pragma glslify: export(random)