Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
interleaving two fragment shaders:
precision highp float;
uniform float time;
uniform vec2 mouse;
uniform vec2 resolution;
#pragma glslify: balls = require(./balls, time=time, mouse=mouse, resolution=resolution)
#pragma glslify: sauron = require(./sauron, time=time, mouse=mouse, resolution=resolution)
int modulo(float x, float y) {
return int(x - y * floor(x / y));
void main(void) {
ivec2 m = ivec2(modulo(gl_FragCoord.x, 2.), modulo(gl_FragCoord.y, 2.));
if(m.x == 0 || m.y == 0) {
} else {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.