46 vec4 K=vec4(1.0,2.0/3.0,1.0/3.0,3.0);
47 vec3 p=abs(fract(c.xxx+K.xyz)*6.0-K.www);
48 return c.z*mix(K.xxx,clamp(p-K.xxx,0.0,1.0),c.y);
113 vec3 pink = vec3(1.0, 0.15, 0.75);
114 vec3 blue = vec3(0.10, 0.55, 1.0);
115 vec3 green = vec3(0.10, 1.00, 0.45);
116 float ph = fract(t*0.08);
117 vec3 k1 = mix(pink, blue, smoothstep(0.00, 0.33, ph));
118 vec3 k2 = mix(blue, green, smoothstep(0.33, 0.66, ph));
119 vec3 k3 = mix(green, pink, smoothstep(0.66, 1.00, ph));
120 float a = step(ph, 0.33);
121 float b = step(0.33, ph) * step(ph, 0.66);
122 float c = step(0.66, ph);
123 return normalize(a*k1 + b*k2 + c*k3) * 1.05;
132 c = pow(max(c, 0.0), vec3(0.95));
133 float l = dot(c, vec3(0.299,0.587,0.114));
134 c = mix(vec3(l), c, 0.9);
135 return clamp(c, 0.0, 1.0);
147 vec3 s00 = textureGrad(img, uv + ts*vec2(-1.0,-1.0), dFdx(uv), dFdy(uv)).rgb;
148 vec3 s10 = textureGrad(img, uv + ts*vec2( 0.0,-1.0), dFdx(uv), dFdy(uv)).rgb;
149 vec3 s20 = textureGrad(img, uv + ts*vec2( 1.0,-1.0), dFdx(uv), dFdy(uv)).rgb;
150 vec3 s01 = textureGrad(img, uv + ts*vec2(-1.0, 0.0), dFdx(uv), dFdy(uv)).rgb;
151 vec3 s11 = textureGrad(img, uv, dFdx(uv), dFdy(uv)).rgb;
152 vec3 s21 = textureGrad(img, uv + ts*vec2( 1.0, 0.0), dFdx(uv), dFdy(uv)).rgb;
153 vec3 s02 = textureGrad(img, uv + ts*vec2(-1.0, 1.0), dFdx(uv), dFdy(uv)).rgb;
154 vec3 s12 = textureGrad(img, uv + ts*vec2( 0.0, 1.0), dFdx(uv), dFdy(uv)).rgb;
155 vec3 s22 = textureGrad(img, uv + ts*vec2( 1.0, 1.0), dFdx(uv), dFdy(uv)).rgb;
156 return (s00 + 2.0*s10 + s20 + 2.0*s01 + 4.0*s11 + 2.0*s21 + s02 + 2.0*s12 + s22) / 16.0;
166 vec2 gdir = normalize(vec2(cos(
time_f*0.27), sin(
time_f*0.31)));
168 float w = max(fwidth(s)*4.0, 0.002);
169 float band = smoothstep(-0.5-w, -0.5+w, sin(s*2.2 +
time_f*0.9));
171 vec3 grad = mix(tex, mix(tex,
neon, 0.6), 0.35 + 0.25*band);
172 grad = mix(grad, tex, 0.10);
206 vec4 baseTex = texture(samp, tc);
208 vec2 uv = tc * 2.0 - 1.0;
210 float radius = mix(0.8, 1.2, 0.5 + 0.5 * sin(
time_f * 1.3));
212 float r = length(uv);
213 float glow = smoothstep(radius, radius - 0.25, r);
217 vec2 ar = vec2(aspect, 1.0);
221 float seg = 4.0 + 2.0*sin(
time_f*0.33);
222 vec2 kUV =
reflectUV(tc, seg, m, aspect);
224 float foldZoom = 1.45 + 0.55 * sin(
time_f * 0.42);
229 vec2 p = (kUV - m) * ar;
230 vec2 q = abs(p);
if(q.y > q.x) q = q.yx;
232 float base = 1.82 + 0.18*sin(
time_f*0.2);
233 float period = log(base);
236 float ang = atan(q.y, q.x) + tz * 0.35 + 0.35*sin(rD*18.0 +
time_f*0.6);
237 float k = fract((log(rD) - tz) / period);
238 float rw = exp(k * period);
239 vec2 pwrap = vec2(cos(ang), sin(ang)) * rw;
241 vec2 u0 = fract(pwrap / ar + m);
242 vec2 u1 = fract((pwrap*1.045) / ar + m);
243 vec2 u2 = fract((pwrap*0.955) / ar + m);
245 vec2 dir = normalize(pwrap + 1e-6);
246 vec2 off = dir * (0.0015 + 0.001 * sin(
time_f*1.3)) * vec2(1.0, 1.0/aspect);
248 float vign = 1.0 - smoothstep(0.75, 1.2, length((tc - m)*ar));
249 vign = mix(0.9, 1.15, vign);
254 vec3 kaleidoRGB = vec3(rC.r, gC.g, bC.b);
256 float ring = smoothstep(0.0, 0.7, sin(log(rD+1e-3)*9.5 +
time_f*1.2));
257 float pulse = 0.5 + 0.5*sin(
time_f*2.0 + rD*28.0 + k*12.0);
259 vec3 outCol = kaleidoRGB;
260 outCol *= (0.75 + 0.25*ring) * (0.85 + 0.15*pulse) * vign;
261 vec3
bloom = outCol*outCol*0.18 + pow(max(outCol-0.6,0.0), vec3(2.0))*0.12;
263 outCol = mix(outCol, baseCol, 0.18);
264 outCol = clamp(outCol, vec3(0.05), vec3(0.97));
266 vec3 finalRGB = mix(baseTex.rgb, outCol,
pingPong(glow *
PI, 5.0) * 0.8);
267 color = vec4(finalRGB, baseTex.a);
vec2 rotateUV(vec2 uv, float angle, vec2 c, float aspect)
Evaluates rotateUV for this shader effect.
vec2 reflectUV(vec2 uv, float segments, vec2 c, float aspect)
Evaluates reflectUV for this shader effect.