- Author:
- Inopia/Aardbei
- Twitter:
- @
- GitHub:
- Facebook:
- Google+:
- +
- Reddit:
- /r/
- Pouet:
- Website:
- Compo:
- classic
- Demo link:
- https://js1k.com/2010-first/demo/250
- Shortlink:
- https://js1k.com/250
- Blog post:
- please update here!
- Bytes:
- 1019
- Chars:
- 1019
- Submission
w=800;h=300;M=Math;S=M.sin;O=M.cos;F="fillStyle";L="fillText";D="drawImage";X="Aardbei";R=M.random;N=M.PI*2;c=(d=document).getElementById("c");function I(e){r=e||d.createElement("canvas");r.width=w;r.height=h;r.C=r.getContext("2d");return r}b=[I(),I()];I(c);k=128;W=[];for(i=0;i<k;i++)W.push({a:R()*N,z:R()});T=0;setInterval(function(){with(n=b[0].C){n[F]="#000";fillRect(0,0,w,h);font="220px arial"}for(var e=0,f;f=W[e];e++)with(f){with(n=b[0].C){n[F]="hsl(0,0%,"+z*100+"%)";beginPath();o=function(){lineTo(S(A)/Z+w/2,O(A)/Z+h/2)};l=0.1;Z=(1.2-z-l)/k;A=a-l;o();l*=2;A+=l;o();Z+=l/k;o();A-=l;o();fill()}z+=0.08;if(z>1){a=R()*N;z=0}}J=h/2+50;m=N/12;t=T/10;r=20;with(b[0]){for(e=0;e<12;e++){C[F]="hsl("+(e-t)*10+",100%,50%)";C[L](X,S((t+e)*m)*r+25,J+O((t+e)*m)*r+5)}C[F]="#fff";C[L](X,20,J)}z=-S(T/30)/k;z=M.max(z,0);for(e=0;e<8;e++){with(n=b[(e+1)%2].C){n[D](s=b[e%2],0,0,w,h);save();globalAlpha=0.5;translate(-z*(S(T/39)+1)*w/2,-z*(O(T/k)+1)*h/2);scale(1+z,1+z);n[D](s,0,0,w,h);restore()}z*=2}c.C[D](b[0],0,0);T++},50);
- Description
- Recursive radial blur.
- Base64 encoded
dz04MDA7aD0zMDA7TT1NYXRoO1M9TS5zaW47Tz1NLmNvcztGPSJmaWxsU3R5bGUiO0w9ImZpbGxUZXh0IjtEPSJkcmF3SW1hZ2UiO1g9IkFhcmR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2JhbEFscGhhPTAuNTt0cmFuc2xhdGUoLXoqKFMoVC8zOSkrMSkqdy8yLC16KihPKFQvaykrMSkqaC8yKTtzY2FsZSgxK3osMSt6KTtuW0RdKHMsMCwwLHcsaCk7cmVzdG9yZSgpfXoqPTJ9Yy5DW0RdKGJbMF0sMCwwKTtUKyt9LDUwKTs=
- Original source
w=800;
h=300;
M=Math;
S=M.sin;
O=M.cos;
F='fillStyle';
L='fillText';
D='drawImage';
X='Aardbei';
R=M.random;
N=M.PI*2;
c=(d=document).getElementById('c');
function I(c)
{
r=c||d.createElement('canvas');
r.width=w;r.height=h;
r.C=r.getContext('2d');
return r;
}
b=[I(),I()];I(c);
k=128;
W = []; for (i=0; i<k; i++) W.push({ a : R()*N, z : R() });
T=0;
setInterval(function()
{
with(n=b[0].C)
{
n[F]='#000';
fillRect(0,0,w,h);
font = '220px arial';
}
for (var i=0,U;U=W[i]; i++) {
with(U) {
with(n=b[0].C)
{
n[F]='hsl(0,0%,'+z*100+'%)';
beginPath();
o=function(){lineTo(S(A)/Z+w/2,O(A)/Z+h/2);};l=0.1;Z=(1.2-z-l)/k;A=a-l;o();l*=2;A+=l;o();Z+=l/k;o();A-=l;o();
fill();
}
z+=0.08; if (z>1){ a = R()*N, z = 0; }
}
}
J=h/2+50;
m=N/12;t=T/10;r=20;
with(b[0])
{
for (var i=0; i<12; i++)
{
C[F] = 'hsl('+(i-t)*10+',100%,50%)';
C[L](X,S((t+i)*m)*r+25,J+O((t+i)*m)*r+5);
}
C[F]='#fff';
C[L](X,20,J);
}
z=-S(T/30)/100;z=M.max(z,0);
for (i=0; i<8; i++)
{
with(n=b[(i+1)%2].C)
{
n[D](s=b[i%2],0,0,w,h);
save();
globalAlpha=0.5;
translate(-z*(S(T/39)+1)*w/2,-z*(O(T/k)+1)*h/2);
scale(1+z,1+z);
n[D](s,0,0,w,h);
restore();
}
z*=2;
}
c.C[D](b[0],0,0);
T++;
},50);