Uniform - Time

Using a uniform input that is holding the number of seconds since the shader started running, together with some trigonometric functions to animate the transition of the amount of red and blue in the canvas.

#ifdef GL_ES
precision mediump float;
#endif

uniform float u_time;

void main() {
	gl_FragColor = vec4(abs(sin(u_time)),0.0,abs(cos(u_time)),1.0);
}
					

Slow

Slow down the frequency until the color change becomes almost imperceptible.

#ifdef GL_ES
precision mediump float;
#endif

uniform float u_time;

void main() {
	gl_FragColor = vec4(abs(sin(u_time/100.0)),0.0,abs(cos(u_time/100.0)),1.0);
}
					

Fast

Speed it up until you see a single color without flickering.

#ifdef GL_ES
precision mediump float;
#endif

uniform float u_time;

void main() {
	gl_FragColor = vec4(0.0,0.0,abs(cos(u_time)*1000.0),1.0);
}
					

Based on 'Uniforms' - https://thebookofshaders.com