Posted on

Read my story on here about this illusion.

To change the colors, you can play with the following functions and observe :-)

    vec3 color = colorDirection > 0.0 
                 ? mix(vec3(1.0, 1.0, 0.0), vec3(0.0, 0.0, 0.0), r / (size * 1.0))
                 : mix(vec3(0.0, 0.0, 0.0), vec3(1.0, 1.0, 0.0), r / (size * 1.0));

    return vec4(color, petalMask);
}