0xc74e…009f

All memos sent from and to 0xc74e…009f.

(()=>{"use strict";{class t{constructor(t){this.r=new function(t){let e=0,n=t>>0,o=t>>32,r=0;return function(){e|=0,n|=0,o|=0,r|=0;let t=(e+n|0)+r|0;return r=r+1|0,e=n^n>>>9,n=o+(o<<3)|0,o=o<<21|o>>>11,o=o+t|0,(t>>>0)/4294967296}}(t);for(let t=0;t<32;t++)this.r()}}let e=new t(42),n=[];for(let t=0;t<600;++t)n.push(t);let o=n.length;for(;0!==o;){let t=Math.floor(e.r()*o);o-=1;let r=n[o];n[o]=n[t],n[t]=r}let r=n[parseInt((tokenData.tokenId+"").substr(-4))%n.length];const a=new Image;a.crossOrigin="anonymous";const s=document.createElement("canvas");s.style="position: absolute; display: block; inset: 0px; margin: auto; width: auto; height: 100%;";const i=s.getContext("2d");a.onload=function(){s.width=a.width,s.height=a.height,i.drawImage(a,0,0),document.body.prepend(s)};let l=tokenData.preferredArweaveGateway+tokenData.externalAssetDependencies[0].cid+"/";a.src=l+(r+"").padStart(3,"0")+".jpg"}})();
Drawing inspiration from nature's healing energy and the serene swaying, this project captures the dynamic essence of light and color. Through iterative coding and sensor-based interaction, the artwork reflects the tranquil beauty and color gradients of Akoya Pearl shell, reminiscent of the sea's tranquil depths.
class FastPoisson{constructor(){this.points=[],this.index=0,this.radius=7,this.dead=!1}solve(t){let s=45,e=80;8==t&&(s=25,e=45);let i=this.radius,$=myWidth,h=myHeight,_;i=Math.min(i,$/s*.9),i*=i;let l,r=createVector(R.random_dec(),R.random_dec());for(let a=0;a<e;a++)for(let g=0;g<s;g++){let p=0;for(;;){r=createVector(R.random_dec(),R.random_dec());let x=createVector(r.x+g,r.y+a);x.x/=s,x.y/=e,x.x*=$,x.y*=h;let o=g+a*e,f=g-1+a*e,c=g+(a-1)*e,n=g-1+(a-1)*e,d=g+1+(a-1)*e,y=this.points[f],b=this.points[c],P=this.points[n],u=this.points[d];if(0!=g&&0==a){if(p5.Vector.sub(y,x).magSq()>i){this.points[o]=x;break}}else if(0==g&&0!=a){if(p5.Vector.sub(b,x).magSq()>i){this.points[o]=x;break}}else if(0==g&&0==a){this.points[o]=x;break}else if(0!=g&&0!=a&&g!=s-1){let m=p5.Vector.sub(b,x);p5.Vector.sub(y,x),p5.Vector.sub(P,x),p5.Vector.sub(u,x);let k=m.magSq(),v=m.magSq(),w=m.magSq(),B=m.magSq();if(k>i&&v>i&&w>i&&B>i){this.points[o]=x;break}}else if(0!=g&&0!=a&&g==s-1){let S=p5.Vector.sub(b,x);p5.Vector.sub(y,x),p5.Vector.sub(P,x);let W=S.magSq(),q=S.magSq(),T=S.magSq();if(W>i&&q>i&&T>i){this.points[o]=x;break}}if(++p>1e3)break}}}render(t,s){for(let e=0;e<this.points.length;e++)if(this.points[e]){let i=this.points[e],$=i.x,h=i.y,_=R.random_num(5,7),l=palettes.getBg(R.random_num(0,1)),r=R.random_num(0,TWO_PI);0==s?drawCherryBlossom(t,$,h,_,l,r,0):1==s&&drawMum(t,$,h,3*_,l,r)}}}class Fabric{constructor(t,s){this.spacing=t,this.bgType=s,this.sw=.05*t,this.hexBgPs=[],this.gridBgPs=[],this.hexps=[],this.hexps2=[],this.gridps=[],this.buildPsArrays()}buildPsArrays(){let t=this.spacing,s=.5*t,e=myHeight/t+1,i=myWidth/(.866*t)+1;for(let $=0;$<e;$++)for(let h=0;h<i;h++){let _=h*t*.866,l=$*t;h%2==0&&(l+=s),this.hexBgPs.push({x:_,y:l,i:$,j:h})}this.hexBgPs.sort((t,s)=>t.y-s.y),e=myHeight/t+1,i=myWidth/s+1;for(let r=0;r<e;r++)for(let a=0;a<i;a++){let g=a*s,p=r*t;a%2==0&&(p+=s),this.gridBgPs.push({x:g,y:p,i:r,j:a})}this.gridBgPs.sort((t,s)=>t.y-s.y);let x=TWO_PI/6;for(let o=0;o<6;o++){let f=x*(o+.5),c=cos(f),n=sin(f);this.hexps.push({x:c,y:n,t:f}),f+=.5*x,c=cos(f),n=sin(f),this.hexps2.push({x:c,y:n,t:f})}x=TWO_PI/4;for(let d=0;d<4;d++){let y=x*(d+.5),b=cos(y),P=sin(y);this.gridps.push({x:b,y:P})}}drawFabric(t){if(t.background(palettes.getBg(0)),this.bgType<=6){t.stroke(palettes.getBg(1)),t.strokeWeight(this.sw);let s=R.random_int(0,2);for(let e of this.hexBgPs){let i=e.x,$=e.y,h=e.i,_=e.j;0==this.bgType?this.drawHexWeave(t,i,$,this.spacing):1==this.bgType?this.drawDiamondWaves(t,i,$,this.spacing):2==this.bgType?this.drawCircleWaves(t,i,$,h,_,this.spacing,s):3==this.bgType?this.drawHempLeaves(t,i,$,h,_,this.spacing):4==this.bgType?this.drawHexWeave2(t,i,$,this.spacing):5==this.bgType?this.drawBasketWeave(t,i,$,h,_,this.spacing,s):6==this.bgType&&this.drawHexStars(t,i,$,h,_,this.spacing,s)}}else 7==this.bgType?poisson.render(t,0):8==this.bgType&&poisson.render(t,1)}drawHexWeave(t,s,e,i){let $=.6*i,h=.3*i;t.noStroke();for(let _=0;_<6;_+=2){let l=map(_,0,6,0,1,!0),r=[],a=_,g=(_+1)%6,p=(_+5)%6,x=this.hexps[a].x,o=this.hexps[a].y,f=this.hexps[g].x,c=this.hexps[g].y,n=this.hexps[p].x,d=this.hexps[p].y,y=s,b=e,P=s+f*$,u=e+c*$,m=P+n*h,k=u+d*h,v=s+x*h,w=e+o*h,B=s+n*$,S=e+d*$,W=B+f*h,q=S+c*h;for(let T of(r.push({x:y,y:b}),r.push({x:P,y:u}),r.push({x:m,y:k}),r.push({x:v,y:w}),r.push({x:W,y:q}),r.push({x:B,y:S}),t.fill(palettes.getBg(l)),t.beginShape(),r))t.vertex(T.x,T.y);t.endShape(CLOSE)}}drawDiamondWaves(t,s,e,i){let $=.05*i;for(let h=0;h<4;h++){let _=map(h,0,3,.25,1),l=lerp(0,i,_),r=this.hexps[3].x,a=this.hexps[3].y,g=this.hexps[4].x,p=this.hexps[4].y,x=this.hexps[5].x,o=this.hexps[5].y;drawDottedLine(t,s+r*l,e+a*l,s+g*l,e+p*l,2*h+2,$),drawDottedLine(t,s+g*l,e+p*l,s+x*l,e+o*l,2*h+2,$)}}drawHexStars(t,s,e,i,$,h,_){let l=.15*h,r=.5*l,a=.25*h,g=this.hexps[4].x,p=this.hexps[4].y,x=this.hexps[3].x,o=this.hexps[3].y,f=this.hexps[5].x,c=this.hexps[5].y;if(i%3==(2+($+1)%2)%3){drawDottedLine(t,s+g,e+p,s+g*h,e+p*h,3,l);for(let n=1;n<6;n+=2){let d=n,y=this.hexps[d].x,b=this.hexps[d].y;t.line(s+y*r,e+b*r,s+y*a,e+b*a)}}else if(i%3==(1+($+1)%2)%3){drawDottedLine(t,s+x,e+o,s+x*h,e+o*h,3,l),drawDottedLine(t,s+f,e+c,s+f*h,e+c*h,3,l);for(let P=0;P<6;P+=2){let u=P,m=this.hexps[u].x,k=this.hexps[u].y;t.line(s+m*r,e+k*r,s+m*a,e+k*a)}}else if(i%3==(0+($+1)%2)%3){for(let v=0;v<6;v++){let w=v,B=this.hexps[w].x,S=this.hexps[w].y;t.line(s+B*r,e+S*r,s+B*a,e+S*a)}drawDottedHex(t,this.hexps,s,e,.6*h),0==_?drawDottedHex(t,this.hexps,s,e,.4*h):2==_&&drawDottedHex(t,this.hexps,s,e,.8*h)}}drawBasketWeave(t,s,e,i,$,h,_){let l=.15*h,r=.8;1==_?r=.7:2==_&&(r=.8);let a=h*r,g=.65*h;if(i%3==(0+($+1)%2)%3){for(let p=0;p<6;p++){let x=p,o=(p+1)%6,f=this.hexps2[x].x*a,c=this.hexps2[x].y*a,n=this.hexps2[o].x*a,d=this.hexps2[o].y*a,y=this.hexps2[x].x*g,b=this.hexps2[x].y*g,P=this.hexps2[o].x*g,u=this.hexps2[o].y*g,m=n-f,k=d-c;n=f+2*m,d=c+2*k,0==_?(t.strokeWeight(.5*this.sw),t.line(s+f,e+c,s+n,e+d),t.strokeWeight(2*this.sw),t.line(s+y,e+b,s+P,e+u)):drawDottedLine(t,s+f,e+c,s+n,e+d,5,l)}1==_?(drawDottedHex(t,this.hexps2,s,e,.5*h),drawDottedHex(t,this.hexps2,s,e,.6*h)):2==_&&(t.fill(palettes.getBg(1)),t.circle(s,e,.75*h))}}drawCircleWaves(t,s,e,i,$,h,_){let l=palettes.getBg(0),r=palettes.getBg(1);t.stroke(l);let a;if(0==_?a=8:1==_?a=int(map(noise(.008*s,.2*e),.25,.75,6,9,!0)):2==_&&(a=10),t.fill(color(0,45)),t.circle(s,e,2.1*h),2==_){if(i%2==0&&$%2==0)t.fill(r),t.circle(s,e,1.9*h),t.fill(l),t.circle(s,e,1.8*h);else for(let g=0;g<a;g++){let p=map(g,0,a-1,0,1),x=lerp(.95*h,h/a,p);t.fill(lerpColor(r,l,g%2)),t.circle(s,e,2*x)}}else for(let o=0;o<a;o++){let f=map(o,0,a-1,0,1),c=lerp(.95*h,h/a,f);t.fill(lerpColor(r,l,o%2)),t.circle(s,e,2*c)}}drawHempLeaves(t,s,e,i,$,h){let _=.5*h,l=.6*h;for(let r of this.hexps){let a=r.x,g=r.y;t.line(s,e,s+a*_,e+g*_)}for(let p of this.hexps2){let x=p.x,o=p.y;t.line(s,e,s+x*l,e+o*l)}}drawDottedWaves(t,s,e,i,$,h){t.noStroke(),t.fill(palettes.getBg(1)),t.circle(s,e,2*h),t.stroke(palettes.getBg(0));for(let _=0;_<8;_++){let l=map(_,0,7,0,1);drawDottedArc(t,s,e,.6*TWO_PI,.9*TWO_PI,lerp(.95*h,h/8,l),3)}}drawHexWeave2(t,s,e,i){let $=.1*i,h=.2*i,_=.225*i;for(let l=0;l<6;l+=2){let r=l,a=(l+1)%6,g=(l+5)%6,p=this.hexps[r].x,x=this.hexps[r].y,o=(this.hexps[r].t+10*TWO_PI)%TWO_PI/TWO_PI,f=this.hexps[a].x,c=this.hexps[a].y,n=(this.hexps[a].t+10*TWO_PI)%TWO_PI/TWO_PI,d=this.hexps[g].x,y=this.hexps[g].y,b=(this.hexps[g].t+10*TWO_PI)%TWO_PI/TWO_PI;t.stroke(palettes.getIri(o,50)),drawDottedLine(t,s,e,s+p*h*3,e+x*h*3,3,$),t.stroke(palettes.getIri(n,50)),drawDottedLine(t,s+f*_,e+c*_,s+f*_+p*_*2,e+c*_+x*_*2,3,$),t.stroke(palettes.getIri(b,50)),drawDottedLine(t,s+d*_,e+y*_,s+d*_+p*_*2,e+y*_+x*_*2,3,$)}}drawHempLeaves2(t,s,e,i,$,h){let _=1*h,l=.6*h;t.noStroke();for(let r=0;r<6;r++){let a=map(getNoise(s,e,.0025),.25,.75,.8,1,!0),g=map(r,0,6,a,1),p=this.hexps[r].x*_,x=this.hexps[r].y*_,o=this.hexps2[r].x*l,f=this.hexps2[r].y*l;t.strokeWeight(.25),t.stroke(palettes.getBg(1)),t.fill(palettes.getBg(.5*g)),t.beginShape(),t.vertex(s,e),t.vertex(s+p,e+x),t.vertex(s+o,e+f),t.endShape(CLOSE)}}drawSquareWeave(t,s,e,i,$,h){let _=.1*h,l=.25*h,r=.025*h;for(let a=0;a<4;a++){let g=a,p=(a+1)%4,x=this.gridps[g].x*l,o=this.gridps[g].y*l,f=this.gridps[p].x*l,c=this.gridps[p].y*l,n=f-x,d=c-o;$%2==1?drawDottedLine(t,s+(x=f-n*r),e+(o=c-d*r),s+f,e+c,2,_):(f=x+n*r,c=o+d*r,drawDottedLine(t,s+x,e+o,s+f,e+c,4,_))}t.circle(s,e,5)}drawSquareCircles(t,s,e,i,$,h){t.noFill(),t.strokeWeight(.5),t.circle(s,e,1*h),t.circle(s,e,.7*h)}}class Palettes{constructor(){this.fgPalettes=[],this.bgPalettes=[],this.loadPalettes(),this.numPalettes=this.fgPalettes.length,this.id=R.random_int(0,this.numPalettes-1),this.fgcs=[],this.bgcs=[],this.irics=[],this.createColors(this.id)}loadPalettes(){append(this.bgPalettes,[15,15,15,35,35,35]),append(this.fgPalettes,[33,72,106,51,130,18,254,221,210,235,163,177]),append(this.bgPalettes,[15,15,15,45,45,45]),append(this.fgPalettes,[5,5,5,15,15,15,25,25,25,35,35,35]),append(this.bgPalettes,[44,50,130,64,70,150]),append(this.fgPalettes,[49,19,140,33,51,151,112,91,78,168,150,144]),append(this.bgPalettes,[55,63,68,95,103,108]),append(this.fgPalettes,[142,61,39,176,145,112,117,131,141,204,213,218]),append(this.bgPalettes,[117,1,39,157,21,59]),append(this.fgPalettes,[75,75,75,100,88,88,205,111,111,225,144,111]),append(this.bgPalettes,[13,26,40,33,46,60]),append(this.fgPalettes,[23,37,51,68,87,99,206,199,187,142,174,196]),append(this.bgPalettes,[15,26,15,35,46,35]),append(this.fgPalettes,[17,33,14,59,73,63,116,142,121,174,210,213]),append(this.bgPalettes,[20,30,73,40,50,93]),append(this.fgPalettes,[25,36,84,219,68,73,232,203,172,235,143,108]),append(this.bgPalettes,[200,200,200,255,255,255]),append(this.fgPalettes,[0,0,0,10,10,10,25,25,25,55,55,55]),append(this.bgPalettes,[18,44,65,30,50,80]),append(this.fgPalettes,[48,74,95,205,62,62,18,44,65,48,74,95]),append(this.bgPalettes,[15,15,15,45,45,45]),append(this.fgPalettes,[255,255,255,225,225,225,200,200,200,180,180,180]),append(this.bgPalettes,[65,45,25,85,65,45]),append(this.fgPalettes,[75,55,35,165,85,105,95,75,55,185,105,125]),append(this.bgPalettes,[254,55,19,253,29,0]),append(this.fgPalettes,[255,80,50,0,37,189,0,52,221,0,92,255]),append(this.bgPalettes,[0,75,28,0,48,16]),append(this.fgPalettes,[0,221,90,255,210,0,0,244,130,255,198,0])}createColors(t){let s=this.bgPalettes[t],e=this.fgPalettes[t];this.fgcs=[];for(let i=0;i<4;i++){let $=3*i,h=e[$+0],_,l=color(h,e[$+1],e[$+2]);append(this.fgcs,l)}this.bgcs=[];for(let r=0;r<2;r++){let a=3*r,g=s[a+0],p,x=color(g,s[a+1],s[a+2]);append(this.bgcs,x)}this.irics=[],append(this.irics,color(255,150,255)),append(this.irics,color(150,150,255)),append(this.irics,color(150,255,255)),append(this.irics,color(150,255,150)),append(this.irics,color(255,255,150))}getFg(t,s){let e,i;for(let $=0;$<3;$++)if(t<=($+1)*.3334){e=map(t,.3334*$,($+1)*.3334,0,1),i=lerpColor(this.fgcs[$],this.fgcs[$+1],e);break}return void 0!==s?color(red(i),green(i),blue(i),s):i}getBg(t,s){let e=lerpColor(this.bgcs[0],this.bgcs[1],t);return void 0!==s?color(red(e),green(e),blue(e),s):e}getIri(t,s){let e,i;for(let $=0;$<4;$++)if(t<=($+1)*.25){e=map(t,.25*$,($+1)*.25,0,1),i=lerpColor(this.irics[$],this.irics[$+1],e);break}return void 0!==s?color(red(i),green(i),blue(i),s):i}getRandom(){return color(R.random_num(25,255),R.random_num(25,255),R.random_num(25,255))}}
let DEBUG=!1,SAVEFRAMES=!1,myWidth=900,myHeight=1600,halfWidth=myWidth/2,halfHeight=myHeight/2,imgScale=2,imgWidth=myWidth/imgScale,imgHeight=myHeight/imgScale,drawWidth,drawHeight,currentHash="",buffer,numCanvases=6,canvases=[],img,gfx,palettes,numPalettes,palette_id,fgPalettes=[],bgPalettes=[],fgcs=[],bgcs=[],iris=[],PALETTE,poisson,fabric,sakuraPs=[],embSakuraPs=[],mumPs=[],shx=1,shy=.5,roads=[],spawns=[],flowers=[],currentFrame=0,maxFrameCount=3e3,MAX_GEN=15,nOffsetX,nOffsetY,MAIN_RAND,IS_ANGLE_LOCKED,ANGLE_LOCK_GEN,BACKGROUND_ID,BACKGROUND_SPACING,SPAWN_ID,ZONE_ID,PRIMARY_CURVATURE,SECONDARY_CURVATURE,IS_TRADITIONAL,BG_DETAIL,numStripes,renderGridRes=1,prefillDotRadius,prefillGridXCount,prefillGridYCount,prefillRad0,prefillRad1,prefillRad2;class Random{constructor(){this.useA=!1;let t=function(t){let e=parseInt(t.substr(0,8),16),i=parseInt(t.substr(8,8),16),$=parseInt(t.substr(16,8),16),s=parseInt(t.substr(24,8),16);return function(){$|=0;let t=((e|=0)+(i|=0)|0)+(s|=0)|0;return s=s+1|0,e=i^i>>>9,i=$+($<<3)|0,$=($=$<<21|$>>>11)+t|0,(t>>>0)/4294967296}};this.prngA=new t(tokenData.hash.substr(2,32)),this.prngB=new t(tokenData.hash.substr(34,32));for(let e=0;e<1e6;e+=2)this.prngA(),this.prngB()}random_dec(){return this.useA=!this.useA,this.useA?this.prngA():this.prngB()}random_num(t,e){return t+(e-t)*this.random_dec()}random_int(t,e){return Math.floor(this.random_num(t,e+1))}random_bool(t){return this.random_dec()<t}random_choice(t){return t[this.random_int(0,t.length-1)]}}function readColor(t,e){let i=4*(e*imgWidth+t);if(i>=img.pixels.length-3)return print("index out of range"),color(255,0,0,255);{let $=img.pixels[i+0],s;return color($,img.pixels[i+1],img.pixels[i+2],255)}}function writeColor(t,e,i,$,s){let r=4*(e*imgWidth+t);img.pixels[r+0]=i,img.pixels[r+1]=$,img.pixels[r+2]=s,img.pixels[r+3]=255}function writeCircle(t,e,i,$){gfx.clear(),gfx.fill($),gfx.ellipse(gfx.width/2,gfx.height/2,100,100),img.copy(gfx,0,0,gfx.width,gfx.height,t-i,e-i,2*i,2*i)}function writeRect(t,e,i,$,s){gfx.clear(),gfx.fill(s),gfx.rect(0,0,100,100),img.copy(gfx,0,0,gfx.width,gfx.height,t,e,i,$)}function getNoise(t,e,i){let $;return map(noise(t*i+nOffsetX,e*i+nOffsetY),.1,.9,0,1,!0)}function createGridSpawn(t,e,i,$,s){for(let r=0;r<t;r++)for(let h=0;h<e;h++){let a=map(r,-.5,t-.5,0,1),l=map(h,-.5,e-.5,0,1),n;addRoad(a*myWidth+i,l*myHeight+a*myHeight*.5+$,s,0,0)}}function createCircleSpawn(t,e,i,$,s){for(let r=0;r<$;r++){let h=map(r,0,$,0,TWO_PI),a=cos(h)*i,l=sin(h)*i;addRoad(t+a,e+l,h+s,0,0)}}function createWavySpawn(t,e,i){for(let $=0;$<t;$++){let s=$*myHeight*.05,r=.45*$;for(let h=0;h<e;h++){let a=map(h,0,e,0,1),l=myWidth*a,n=i+80*sin(a*PI*2+r+.05*i)+s+a*myHeight*.5;addRoad(l,n,HALF_PI,0,0)}}}function addRoad(t,e,i,$){let s=new Road(t,e,i,$);roads.push(s)}function addSpawn(t,e,i,$){let s=new Spawn(t,e,i,$);spawns.push(s)}function drawEmbroideredRing(t,e,i,$,s,r){for(let h=i-$;h<i+$;h+=r){let a=e-sqrt(sq($)-sq(h-i)),l=e+sqrt(sq($)-sq(h-i));if(a>=e-$&&l<=e+$){let n=e-sqrt(sq(s)-sq(h-i)),d=e+sqrt(sq(s)-sq(h-i));h>i-s&&h<i+s?(t.line(a,h,n,h),t.line(d,h,l,h)):t.line(a,h,l,h)}}}function drawDottedLine(t,e,i,$,s,r,h){let a=dist(e,i,$,s),l=(a-h*r)/r;for(let n=0;n<r;n++){let d=.5*h+n*(l+h),o=lerp(e,$,d/a),g=lerp(i,s,d/a),m=lerp(e,$,(l+d)/a),f=lerp(i,s,(l+d)/a);t.line(o,g,m,f)}}function drawDottedHex(t,e,i,$,s){for(let r=0;r<6;r++){let h=r,a=(r+1)%6,l=e[h].x*s,n=e[h].y*s,d;drawDottedLine(t,i+l,$+n,i+e[a].x*s,$+e[a].y*s,2,3)}}function drawDottedArc(t,e,i,$,s,r,h){let a=floor((s-$)*r/h),l=(s-$)/a;for(let n=0;n<=a;n++){let d=$+n*l,o=e+r*cos(d),g=i+r*sin(d);t.point(o,g)}}function drawStitchedCircle(t,e,i,$,s,r,h,a){let l=h+a,n=TWO_PI*r,d=n/l;t.stroke($),t.strokeWeight(s);for(let o=0;o<d;o++){let g=o*l/n*TWO_PI,m=g+h/n*TWO_PI,f=e+r*cos(g),c=i+r*sin(g),u=e+r*cos(m),p=i+r*sin(m);t.line(f,c,u,p)}}function drawStitchedLine(t,e,i,$,s,r,h,a,l){let n=dist(e,i,$,s),d=a+l,o=n/d;t.stroke(r),t.strokeWeight(h);for(let g=0;g<o;g++){let m=g*d/n,f=(g*d+a)/n;f=min(f,1);let c=lerp(e,$,m),u=lerp(i,s,m),p=lerp(e,$,f),y=lerp(i,s,f);t.line(c,u,p,y)}}function drawStitch(t,e,i,$,s,r,h,a,l,n,d){t.strokeWeight(a),t.stroke(palettes.getBg(0)),t.line($+shx,s+shy,r+shx,h+shy),e.strokeWeight(.25*a),e.stroke(d),e.line($,s,r,h);let o=.5*sin(2*n)+.5;i.strokeWeight(l),i.stroke(palettes.getIri(o,255*o)),i.line($-shx,s-shy,r-shx,h-shy)}function storeSakuraPs(){sakuraPs.push({x:0,y:.05}),sakuraPs.push({x:-.3,y:.5}),sakuraPs.push({x:-.3,y:.75}),sakuraPs.push({x:-.1,y:1}),sakuraPs.push({x:0,y:.9}),sakuraPs.push({x:.1,y:1}),sakuraPs.push({x:.3,y:.75}),sakuraPs.push({x:.3,y:.5}),sakuraPs.push({x:0,y:.05})}function storeEmbSakuraPs(){TWO_PI;let t=75;for(let e=0;e<t;e++){let i=map(e%15,0,15,0,1),$=pow(sin(i*PI),25),s=map(e,0,t,0,TWO_PI),r=map(e,0,t,0,5*PI),h=cos(s),a=sin(s),l=pow(abs(sin(r)),.25),n=h*(l-=.125*$),d=a*l;embSakuraPs.push({x:n,y:d,theta:s})}}function storeMumPs(){TWO_PI;for(let t=0;t<16;t++){let e=map(t,0,16,0,TWO_PI),i=cos(e),$=sin(e);mumPs.push({x:i,y:$})}}function sign(t){return t>0?1:t<0?-1:0}function roundAngle(t,e,i){let $=TWO_PI/e;return round(t/$)*$+i}function preload(){for(let t=0;t<numCanvases;t++){let e=createGraphics(myWidth,myHeight);e.noStroke(),append(canvases,e)}windowResized()}function prefillImg(t){(img=createImage(imgWidth,imgHeight)).loadPixels();for(let e=0;e<imgWidth;e++)for(let i=0;i<imgHeight;i++)img.set(e,i,color(0,0,0));if(img.updatePixels(),1==t){prefillDotRadius=R.random_num(10,30),prefillGridXCount=R.random_int(2,4),prefillGridYCount=R.random_int(2,6);let $=prefillDotRadius,s=2*$,r=prefillGridXCount,h=prefillGridYCount,a=color(15,15,15);for(let l=0;l<r;l++)for(let n=0;n<h;n++){let d=map(l,-.5,r-.5,0,1),o=map(n,-.5,h-.5,0,1),g=d*imgWidth,m=o*imgHeight+d*imgHeight*.5;writeCircle(g,m,s,a),g>imgWidth-$?writeCircle(g-=imgWidth,m,s,a):g<$&&writeCircle(g+=imgWidth,m,s,a),m>imgHeight-$?writeCircle(g,m-=imgHeight,s,a):m<$&&writeCircle(g,m+=imgHeight,s,a)}}else if(2==t){prefillRad0=R.random_num(100,250),prefillRad1=R.random_num(50,150),prefillRad2=R.random_num(20,70);let f=.5*imgWidth,c=.5*imgHeight,u=color(15,0,0);writeCircle(f,c,prefillRad0,u),writeCircle(f,c,prefillRad1,u=color(0,15,0)),writeCircle(f,c,prefillRad2,u=color(0,0,15))}else if(3==t){numStripes=R.random_int(2,4);let p=color(10,10,10),y=imgWidth/(2*numStripes),_=imgHeight;for(let w=0;w<numStripes;w++){let S=map(w,.5,numStripes-.5,0,1);writeRect(imgWidth*S,0,y,_,p)}}else if(4==t){let x=color(10,10,10);numStripes=R.random_int(2,7);for(let C=0;C<numStripes;C++){let W=map(C,.5,numStripes-.5,0,1);writeRect(0,imgHeight*W,imgWidth,imgHeight/(2*numStripes),x)}}}function windowResized(){dim=windowWidth<windowHeight?windowWidth:windowHeight,resizeCanvas(windowWidth,windowHeight);let t=myWidth/myHeight;width/height<t?(drawWidth=width,drawHeight=width/t):(drawHeight=height,drawWidth=height*t)}function keyTyped(){"s"==key?saveImage():"d"==key?DEBUG=!DEBUG:"r"==key?RESET=!0:"1"==key?renderGridRes=1:"2"==key?renderGridRes=2:"3"==key?renderGridRes=4:"4"==key&&(renderGridRes=8)}function saveImage(){let t=createGraphics(myWidth,myHeight);t.image(canvases[0],0,0);let e=2;for(let i=0;i<e;i++){let $=map(i,0,e,0,1),s=myWidth/e;for(let r=0;r<=e;r++){let h=myWidth*$,a=map(r,0,e,0,1),l=myHeight/e,n=myHeight*a;i%2==1&&(n-=l/2),t.image(canvases[1],h,n,s,l),t.image(canvases[2],h,n,s,l)}}e=renderGridRes;for(let d=0;d<e;d++){let o=map(d,0,e,0,1),g=myWidth/e;for(let m=0;m<=e;m++){let f=myWidth*o,c=map(m,0,e,0,1),u=myHeight/e,p=myHeight*c;d%2==1&&(p-=u/2);for(let y=1;y<numCanvases;y++)t.image(canvases[y],f,p,g,u)}}save(t,currentHash,"png")}function setupFeatures(){palettes=new Palettes,MAX_GEN=8,MAIN_RAND=R.random_dec(),IS_ANGLE_LOCKED=R.random_bool(.2),ANGLE_LOCK_GEN=R.random_int(0,1),BACKGROUND_ID=R.random_int(0,4),BACKGROUND_SPACING=20,SPAWN_ID=R.random_int(0,6),ZONE_ID=R.random_int(0,4),IS_TRADITIONAL=R.random_bool(.9),BG_DETAIL=R.random_bool(.2),PRIMARY_CURVATURE=R.random_num(1,2),SECONDARY_CURVATURE=R.random_num(.5,2),print("Palette = "+palettes.id),print("Spawn Id = "+SPAWN_ID),print("Background Id = "+BACKGROUND_ID),print("Zone Id = "+ZONE_ID),print("Is Angle Locked = "+IS_ANGLE_LOCKED),print("Angle Lock Gen = "+ANGLE_LOCK_GEN)}function reset(){for(let t of(print("Growth v3"),print(tokenData.hash),print("------------------------------------------------------------------------------"),R=new Random,noiseDetail(5,.5),noiseSeed(R.random_dec()),nOffsetX=R.random_num(150,1300),nOffsetY=R.random_num(150,1300),randomSeed(R.random_dec()),pixelDensity(2),smooth(),saveFrame=!1,currentFrame=0,setupFeatures(),buffer=createCanvas(windowWidth,windowHeight),img=createImage(imgWidth,imgHeight),(gfx=createGraphics(100,100)).noStroke(),prefillImg(ZONE_ID),canvases))t.clear(),t.strokeCap(ROUND),t.background(0,0,0,0);roads=[],spawns=[],flowers=[],storeSakuraPs(),storeEmbSakuraPs(),storeMumPs(),(poisson=new FastPoisson).solve(BACKGROUND_ID),(fabric=new Fabric(BACKGROUND_SPACING,BACKGROUND_ID)).drawFabric(canvases[0]),initialSpawn(),stitchZones(ZONE_ID)}function setup(){windowResized(),reset()}function initialSpawn(){if(0==SPAWN_ID)createWavySpawn(2,75,.25*myHeight),createWavySpawn(2,75,.75*myHeight);else if(1==SPAWN_ID)createGridSpawn(3,4,0,0,0),createGridSpawn(3,4,30,-10,PI);else if(2==SPAWN_ID)createCircleSpawn(halfWidth,halfHeight,.55*myWidth,70,HALF_PI),createCircleSpawn(halfWidth,halfHeight,.35*myWidth,50,PI),createCircleSpawn(halfWidth,halfHeight,.2*myWidth,30,-HALF_PI);else if(3==SPAWN_ID)createCircleSpawn(halfWidth,halfHeight,.55*myHeight,70,HALF_PI),createCircleSpawn(halfWidth,halfHeight,.35*myHeight,50,PI),createCircleSpawn(halfWidth,halfHeight,.2*myHeight,30,-HALF_PI);else if(4==SPAWN_ID)for(let t=0;t<3;t++)for(let e=0;e<4;e++){let i=map(t,-.5,2.5,0,1),$=map(e,-.5,3.5,0,1),s;createCircleSpawn(i*myWidth,$*myHeight+i*myHeight*.5,20,12,0)}else 5==SPAWN_ID?createGridSpawn(3,5,0,0,0):6==SPAWN_ID&&(createCircleSpawn(halfWidth,halfHeight,.35*myHeight,150,PI),createCircleSpawn(halfWidth,halfHeight,.15*myHeight,75,0))}function stitchZones(t){let e=canvases[numCanvases-1],i=palettes.getBg(0),$=palettes.getFg(0);if(1==t){let s=2*prefillDotRadius,r=2*s,h=prefillGridXCount,a=prefillGridYCount;for(let l=0;l<h;l++)for(let n=0;n<a;n++){let d=map(l,-.5,h-.5,0,1),o=map(n,-.5,a-.5,0,1),g=d*myWidth,m=o*myHeight+d*myHeight*.5;drawStitchedCircle(e,g,m,i,8,r,8,4),drawStitchedCircle(e,g,m,$,1.5,r,8,4),g>myWidth-s?(drawStitchedCircle(e,g-=myWidth,m,i,8,r,8,4),drawStitchedCircle(e,g,m,$,1.5,r,8,4)):g<s&&(drawStitchedCircle(e,g+=myWidth,m,i,8,r,8,4),drawStitchedCircle(e,g,m,$,1.5,r,8,4)),m>myHeight-s?(drawStitchedCircle(e,g,m-=myHeight,i,8,r,8,4),drawStitchedCircle(e,g,m,$,1.5,r,8,4)):m<s&&(drawStitchedCircle(e,g,m+=myHeight,i,8,r,8,4),drawStitchedCircle(e,g,m,$,1.5,r,8,4))}}else if(2==t){let f=.5*myWidth,c=.5*myHeight;drawStitchedCircle(e,f,c,i,8,2*prefillRad0,8,4),drawStitchedCircle(e,f,c,$,1.5,2*prefillRad0,8,4),drawStitchedCircle(e,f,c,i,8,2*prefillRad1,8,4),drawStitchedCircle(e,f,c,$,1.5,2*prefillRad1,8,4),drawStitchedCircle(e,f,c,i,8,2*prefillRad2,8,4),drawStitchedCircle(e,f,c,$,1.5,2*prefillRad2,8,4)}else if(3==t){let u=myHeight;for(let p=0;p<numStripes;p++){let y=map(p,.5,numStripes-.5,0,1),_=myWidth*y;drawStitchedLine(e,_,0,_,u,i,8,8,4),drawStitchedLine(e,_,0,_,u,$,1.5,8,4),drawStitchedLine(e,_+=myWidth/(2*numStripes),0,_,u,i,8,8,4),drawStitchedLine(e,_,0,_,u,$,1.5,8,4)}}else if(4==t){let w=myWidth;for(let S=0;S<numStripes;S++){let x=map(S,.5,numStripes-.5,0,1),C=myHeight*x;drawStitchedLine(e,0,C,w,C,i,8,8,4),drawStitchedLine(e,0,C,w,C,$,1.5,8,4),drawStitchedLine(e,0,C+=myHeight/(2*numStripes),w,C,i,8,8,4),drawStitchedLine(e,0,C,w,C,$,1.5,8,4)}}}function update(){if(currentFrame>0){for(let t of(img.loadPixels(),roads))t.update();for(let e of spawns)e.update();for(let i of roads)i.render();img.updatePixels()}}function draw(){if(currentFrame<maxFrameCount){if(update(),currentFrame>0)for(let t of roads)t.drawRoad();cleanUp()}if(image(canvases[0],0,0,drawWidth,drawHeight),BG_DETAIL)for(let e=0;e<3;e++){let i=map(e,0,3,0,1),$=drawWidth/3;for(let s=0;s<=3;s++){let r=drawWidth*i,h=map(s,0,3,0,1),a=drawHeight/3,l=drawHeight*h;e%2==1&&(l-=a/2),image(canvases[1],r,l,$,a)}}gr=renderGridRes;for(let n=0;n<gr;n++){let d=map(n,0,gr,0,1),o=drawWidth/gr;for(let g=0;g<=gr;g++){let m=drawWidth*d,f=map(g,0,gr,0,1),c=drawHeight/gr,u=drawHeight*f;n%2==1&&(u-=c/2);for(let p=2;p<numCanvases;p++)image(canvases[p],m,u,o,c)}}currentFrame++,DEBUG&&image(img,0,0,drawWidth,drawHeight)}function cleanUp(){for(let t=0;t<roads.length;t++)roads[t].isDead()&&roads.splice(t,1);for(let e=0;e<spawns.length;e++)spawns[e].isDead()&&spawns.splice(e,1)}function drawCherryBlossom(t,e,i,$,s,r,h){0==h?plainCherryBlossom(t,e,i,$,s,r):1==h?embroideredCherryBlossom(t,e,i,$,s,r):2==h&&embroideredCherryBlossomOutline(t,e,i,$,s,r)}function plainCherryBlossom(t,e,i,$,s,r){let h=TWO_PI/5;t.fill(s),t.stroke(palettes.getBg(0)),t.strokeWeight(.5),t.push(),t.translate(e,i),t.rotate(r);for(let a=0;a<5;a++){for(let l of(t.rotate(h),t.beginShape(),sakuraPs)){let n=l.x*$,d=l.y*$;t.curveVertex(n,d)}t.endShape(CLOSE)}t.pop()}function embroideredCherryBlossom(t,e,i,$,s,r){for(let h of(TWO_PI,t.push(),t.translate(e,i),t.rotate(r),t.strokeWeight(6),t.stroke(palettes.getBg(0)),embSakuraPs)){let a=h.x*$*.2,l=h.y*$*.2,n=h.x*$,d=h.y*$;t.line(a,l,n,d)}for(let o of(t.strokeWeight(1.5),t.stroke(color(0,20)),embSakuraPs)){let g=o.x*$*.2,m=o.y*$*.2,f=o.x*$,c=o.y*$;t.line(g+shx,m+shy,f+shx,c+shy)}for(let u of(t.strokeWeight(1),t.stroke(s),embSakuraPs)){let p=u.x*$*.2,y=u.y*$*.2,_=u.x*$,w=u.y*$;t.line(p,y,_,w)}for(let S of(t.strokeWeight(.3),embSakuraPs)){let x=S.x*$*.2,C=S.y*$*.2,W=S.x*$,H=S.y*$,A=.5*sin(2*S.theta)+.5;t.stroke(palettes.getIri(A,100*A)),t.line(x-shx,C-shy,W-shx,H-shy)}t.fill(palettes.getBg(1)),t.strokeWeight(1),t.stroke(palettes.getFg(0));for(let k=0;k<15;k++){let P=map(k,0,15,0,1),I=P*TWO_PI,D=$*R.random_num(.35,.4),v=cos(I),N=sin(I),G=v*$*.1,E=N*$*.1,B=v*D,L=N*D;t.fill(palettes.getIri(P,50)),t.line(G,E,B,L),t.circle(B,L,.075*$)}t.pop()}function embroideredCherryBlossomOutline(t,e,i,$,s,r){for(let h of(TWO_PI,t.push(),t.translate(e,i),t.rotate(r),t.fill(palettes.getBg(.5)),t.strokeWeight(.035*$),t.stroke(palettes.getFg(1)),t.beginShape(),embSakuraPs)){h.x,h.y;let a=h.x*$,l=h.y*$;t.vertex(a,l)}t.endShape(CLOSE);for(let n=0;n<15;n++){let d=map(n,0,15,0,1),o=d*TWO_PI,g=$*R.random_num(.35,.4),m=cos(o),f=sin(o),c=m*$*.1,u=f*$*.1,p=m*g,y=f*g;t.fill(palettes.getIri(d,250)),t.line(c,u,p,y),t.circle(p,y,.075*$)}t.pop()}function drawMum(t,e,i,$,s,r){plainMum(t,e,i,$,s,r)}function plainMum(t,e,i,$,s,r){t.fill(s),t.stroke(palettes.getBg(R.random_dec())),t.strokeWeight(.025*$);let h=mumPs.length;for(let a=0;a<h;a++){let l=a,n=(a+1)%h,d=mumPs[l].x,o=mumPs[l].y,g=mumPs[n].x,m=mumPs[n].y;t.beginShape(),t.curveVertex(e,i);for(let f=0;f<5;f++){let c=map(f,0,4,0,1),u=lerp(.8*$,$,sqrt(sin(c*PI))),p=e+lerp(d,g,c)*u,y=i+lerp(o,m,c)*u;t.curveVertex(p,y)}t.curveVertex(e,i),t.endShape(CLOSE)}t.fill(palettes.getBg(R.random_dec())),t.circle(e,i,.45*$)}class Spawn{constructor(t,e,i,$){this.x=t,this.y=e,this.theta=i,this.gen=$,this.age=0,this.life=250,this.dead=!1}update(){this.age++,this.age>this.life&&(addRoad(this.x,this.y,this.theta,this.gen),this.dead=!0)}isDead(){return this.dead}}class Road{constructor(t,e,i,$){this.x=t,this.y=e,this.theta=i,this.gen=$,this.genPer=map(this.gen,0,6,0,1),this.cd=palettes.getFg(fract(this.genPer+R.random_num(0,.05))),this.genPer=map(this.gen,0,3,0,1,!0),this.myRand=R.random_dec(),this.trajThresh=1.3,this.sw=1,this.sw2=3,this.swPer=0,this.ink=palettes.getRandom();let s=constrain(this.x,0,myWidth-1),r=constrain(this.y,0,myHeight-1),h=int(s/imgScale),a=int(r/imgScale);this.bg=readColor(h,a),this.speed=.5,this.xv=cos(this.theta)*this.speed,this.yv=sin(this.theta)*this.speed,this.px=t-this.xv,this.py=e-this.yv,this.age=0,this.life=1e3,this.agePer=this.age/this.life,this.dead=!1;let l=getNoise(this.x,this.y,.005),n=getNoise(this.y,this.x,.005);this.delta=map(l,0,1,-.015,.0075,!0),this.delta2=map(n,0,1,-.001,.001,!0),0==this.gen&&(this.delta=map(MAIN_RAND,0,1,-.01,-.04),this.delta2=15e-5),this.spawnIter=3,this.fillThresh=25,this.stitch=0,this.stitchInterval=7,this.stitchLength=.35*this.stitchInterval,this.stitchCount=0,this.isFlowering=!1}update(){this.dead||(this.updatePosition(),this.checkOverlap(),this.updateTrajectory(),this.updateAge(),this.createSpawn(),this.wrapBorder())}updatePosition(){let t=360;this.gen>=ANGLE_LOCK_GEN&&IS_ANGLE_LOCKED&&(t=6);let e=this.theta;e=roundAngle(this.theta,t,HALF_PI),this.xv=cos(e)*this.speed,this.yv=sin(e)*this.speed,this.px=this.x,this.py=this.y,this.x+=this.xv,this.y+=this.yv}checkOverlap(){let t=constrain(this.x+4*this.xv,0,myWidth-1),e=constrain(this.y+4*this.yv,0,myHeight-1),i=int(t/imgScale),$=int(e/imgScale),s=readColor(i,$),r=brightness(s);0==this.age&&(this.bg=s),r>20?s.toString()!=this.ink.toString()&&(this.dead=!0):this.age>0&&s.toString()!=this.bg.toString()&&(this.dead=!0)}updateTrajectory(){(this.myRand<this.trajThresh||IS_TRADITIONAL)&&(this.theta+=this.delta*PRIMARY_CURVATURE,this.delta+=this.delta2*SECONDARY_CURVATURE),abs(this.delta)>.066&&(this.dead=!0)}updateAge(){this.age++,this.agePer=this.age/this.life,this.age>=this.life&&(this.dead=!0)}createSpawn(){!this.dead&&this.age%this.spawnIter==0&&this.age>this.fillThresh&&this.gen<MAX_GEN&&(currentFrame%2==0?addSpawn(this.x,this.y,this.theta-HALF_PI,this.gen+1):addSpawn(this.x,this.y,this.theta+HALF_PI,this.gen+1))}render(){if(this.age>10){let t=int(this.x/imgScale),e=int(this.y/imgScale),i=red(this.ink),$;writeColor(t,e,i,green(this.ink),blue(this.ink))}}drawRoad(t){this.swPer=map(this.age,10,45,0,1,!0),this.sw=15*pow(map(abs(this.delta),0,.0666,1,0),2)+2+11*pow(1-this.genPer,2),this.sw*=this.swPer,this.sw2=min(this.sw+1,1.2*this.sw),this.stitchLength=.1*this.sw,this.isFlowering&&this.age%49==48&&currentFrame>300&&this.createFlower(),this.age%this.stitchInterval==0&&this.age>10&&(this.drawRunningStitch(),this.stitchCount++)}createFlower(){let t=this.x,e=this.y,i=R.random_num(17,35),$=2*i,s=R.random_int(0,2);this.age%2==0?(t+=this.yv*$,e+=-this.xv*$):(t+=-this.yv*$,e+=this.xv*$);let r=palettes.getFg(this.agePer),h=R.random_num(0,TWO_PI),a=canvases[2];if(drawCherryBlossom(a,t,e,i,r,h,s),t<50?(e<halfHeight?e+=halfHeight:e-=halfHeight,drawCherryBlossom(a,t+myWidth,e,i,r,h,s)):t>myWidth-50&&(e<halfHeight?e+=halfHeight:e-=halfHeight,drawCherryBlossom(a,t-myWidth,e,i,r,h,s)),e<50?drawCherryBlossom(a,t,e+myHeight,i,r,h,s):e>myHeight-50&&drawCherryBlossom(a,t,e-myHeight,i,r,h,s),this.age>10){let l=int(this.x/imgScale),n=int(this.y/imgScale),d=red(this.ink),o;writeColor(l,n,d,green(this.ink),blue(this.ink))}}drawRunningStitch(){let t=5;this.gen>=1&&this.gen<=2?t=4:this.gen>=3&&(t=3),canvases[0];let e=canvases[1],i=canvases[3],$=canvases[4],s=canvases[5],r=this.stitchLength,h=this.x-this.xv*r,a=this.x+this.xv*r,l=this.y-this.yv*r,n=this.y+this.yv*r;e.fill(palettes.getIri(.5,30)),e.circle(this.x,this.y,3),i.strokeWeight(this.sw2),i.stroke(palettes.getBg(0)),i.line(h,l,a,n),$.strokeWeight(.25*this.sw),$.stroke(this.cd),$.line(h,l,a,n);let d=.5*sin(2*this.theta)+.5;s.strokeWeight(1*this.swPer),s.stroke(palettes.getIri(d,255*d)),s.line(h-shx,l-shy,a-shx,n-shy)}wrapBorder(){this.x<0&&(this.x+=myWidth,this.px+=myWidth,this.y<halfHeight?(this.y+=halfHeight,this.py+=halfHeight):(this.y-=halfHeight,this.py-=halfHeight)),this.x>myWidth&&(this.x-=myWidth,this.px-=myWidth,this.y<halfHeight?(this.y+=halfHeight,this.py+=halfHeight):(this.y-=halfHeight,this.py-=halfHeight)),this.y<0&&(this.y+=myHeight,this.py+=myHeight),this.y>myHeight&&(this.y-=myHeight,this.py-=myHeight)}isDead(){return this.dead}}
var s,layout,dome,blobs,blobs2,dark,light,base,today,uH,uD,uM,fastForwardRate,randomMonth,colGap,gR,version=3.9,nBlob=6,nCol=8,uDmaxTimeRange=31,uMmaxTimeRange=12,uHmaxTimeRange=24,rarr=[],rarro=[];function calculateFeatures($){let o=new class o{constructor(){this.useA=!1;let o=function($){let o=parseInt($.substr(0,8),16),l=parseInt($.substr(8,8),16),n=parseInt($.substr(16,8),16),e=parseInt($.substr(24,8),16);return function(){n|=0;let $=((o|=0)+(l|=0)|0)+(e|=0)|0;return e=e+1|0,o=l^l>>>9,l=n+(n<<3)|0,n=(n=n<<21|n>>>11)+$|0,($>>>0)/4294967296}};this.prngA=new o($.hash.substr(2,32)),this.prngB=new o($.hash.substr(34,32));for(let l=0;l<1e6;l+=2)this.prngA(),this.prngB()}random_dec(){return this.useA=!this.useA,this.useA?this.prngA():this.prngB()}random_int($,o){return Math.floor($+(o+1-$)*this.random_dec())}random_choice($){return $[this.random_int(0,$.length-1)]}wRand($){let o,l=0,n=this.random_dec();for(o in $)if(n<=(l+=$[o]))return o}};var l={};return l.layout=o.wRand({ichi:.02,companion:.08,duo:.15,fountain:.75}),l.nBlob="ichi"==l.layout?1:"companion"==l.layout?o.wRand({1:.7,2:.3}):"duo"==l.layout?2:o.random_int(3,7),l.monotone=o.wRand({0:0,1:1}),l.bg=-1!=["ichi","companion","duo"].indexOf(l.layout)?"mountain":o.random_choice(["moor","mountain"]),l.bgCol=-1!=["ichi","companion"].indexOf(l.layout)?["#222","#fff","#111"]:o.random_choice([["#1E0E2D","#07f49e","#111"],["#111","#fff","#111"],["#00113D","#edb144","#051132"],]),l}var features=calculateFeatures(tokenData);function setup(){createCanvas((s=min(windowWidth*(16/9),windowHeight))*(9/16),s,WEBGL);for(let $=0;$<nBlob+1;$++){let o=tokenData.hash.slice(2*$+2,2*$+4);rarro.push(parseInt(o,16)%100/100)}gR=(rarr=scaleArray(rarro))[0],[dark,light,base]=features.bgCol,nBlob=int(features.nBlob),blobs2=selectBlob(features.layout,rarr,nBlob)}function draw(){pixelDensity(2),background(base),angleMode(DEGREES),blendMode(ADD);let $=new Date;uD=$.getDate(),uH=$.getHours(),uM=$.getMonth(),push();let o=.7*s/(.6+nBlob),l=.15*s+o*nBlob;firstBlobCol=drawPal(initAng=round(300*gR)%360,monotone=int(features.monotone),0,nCol)[0][0],drawEarth(features.bg,l,tones=[dark,firstBlobCol]),fill("#208bff00"),"companion"==features.layout?asawa0(nBlob,blobs2,monotone,rarr,uM,o):asawa(nBlob,blobs2,monotone,rarr,uM,o),pop()}function asawa0($,o,l,n,e,b){push(),rotateY(30*gR),gR<.5?rotateY(10*e):rotateY(-(10*e)),j=0,push(),asawa($,o,l,n,e,b),pop(),b/=5,push();let t=gR<.1||2==$?s/5:s/10;translate(-s/5,t),asawa($,o,features.monotone,n,e,b),pop(),push();let a=gR<.1||2==$?0:s/5;translate(2*s/5,a),asawa($,o,features.monotone,n,e,b),pop(),pop()}function asawa($,o,l,n,e,b){push(),translate(0,-s/2);let t=.15*s;for(let a=0;a<$;a++){let _=n[a]<.15?30*e:n[a]<.35?-30*e:0;[pal,innerPal]=drawPal(initAng+_,l,a,nCol);let i=wRand({slice:.75,full:.25},n[a]),u=t+b*a;if(push(),isPolarBlob(o[a]))blobbyBifoliumHeart(o,a,0,u,pal,innerPal,b,e);else for(let f=0;f<2;f++)blobby(f+0,u,o,a,pal,innerPal,b,angIncre=3,dome=i,n[a],e);pop()}}function blobbyBifoliumHeart($,o,l,n,e,b,t,a){push(),translate(l,n),blobi=$[o],o>1&&($[o-1]==blob0||$[o-1]==blob3)&&(a=0);for(let _=30;_<120;_+=2)strokeWeight(sw=selectStroke(_)),push(),rotateY(-(2*_)),stroke(200,200,0),blobi(e,b,o,t,a),pop();for(let i=-60;i<20;i+=2)strokeWeight(sw=selectStroke(i)),push(),rotateY(2*i),stroke(e[0]),blobi(e,b,o,t,a),pop();pop()}function blobby($,o,l,n,e,b,t,a,_,i,u){[ang,span,rot]=drawDome(features.layout,_,i,uH),angLst=[ang,ang+rot];let f=Array(nCol).fill(color(200,200,0));pals=gR<.09?[e,f]:[e,e];let m=2;isPolarBlob(l[n])&&(rot=0,m=1,span=90);for(let g=0;g<m;g++)push(),rotateY(angLst[g]),blobLayer($+(xdispAdj=i<.25&&l.length>2?t/16:0),o,l,n,pals[g],b,t,angLst[g],span,a,i,u),pop()}function isPolarBlob($){return $==blob7}function selectStroke($){return sw=$%5<2?.6:.1618,s>1600&&(sw*=map(s,800,8e3,1,6)),sw}function blobLayer($,o,l,n,e,b,t,a=0,_=180,i=2,u,f){f=int(f),push(),translate($,o);let m=max(0,f-(randomMonth=int(12*u))),g=5+5*sin((m+uD/uDmaxTimeRange/2+gR/2)/uMmaxTimeRange*90);rotateX(0==n&&l.length>1?0:u<.1&&0!=n?g:u<.7?-g:0);for(let h=0;h<_;h+=i)stroke(e[h%nCol]),strokeWeight(sw=selectStroke(h)),push(),rotateY(h),"ichi"==layout&&scale(2.88),l[n]==blob0&&scale(.8),u<.3&&!isPolarBlob(blobs2[n])&&l.length>3||"duo"==features.layout&&0==n||3==l.length&&0==n?(push(),translate(0,t,0),2==l.length&&0==n?scale(.86,-.86,1):scale(1,-1,1),blobs2[n](e,b,h,n,t,u,f),pop()):blobs2[n](e,b,h,n,t,u,f),pop();pop()}function blob0($,o,l,n,e,b=.2,t){stroke($[l%nCol]),push(),rotateY(20*n);let a=2.68*(e*=.8),_=1.88*e,i=.03*e,u=1.43*e;bezier(0,0,a,_,i,u,0,e),b<.2&&n!=nBlob-1?scale(.618,.9):(translate(0,.3*e),scale(.618)),b<.5&&stroke(o[l%nCol]),bezier(0,0,a,_,i,u,0,e),b>.25&&(scale(.5),b<.5&&stroke($[l%nCol]),translate(0,e/2),bezier(0,0,a,_,i,u,0,e)),pop()}function blob1($,o,l,n,e=200,b,t){stroke($[l%nCol]);let a=(.3+.6*b)*e,_=b*e*1.1;bezier(0,0,0,0,a,_,0,e);let i=normaSin(t/uMmaxTimeRange*90),u=i*e*.6,f=i*e*.1;a=f+i*e*.2,_=u+.3*i*e,push(),stroke(o[l%nCol]),scale(.5,.5+.3*b,1),bezier(0,u,f,u,a,_,0,e),pop()}function blob2($,o,l,n,e=200,b,t){stroke($[l%nCol]),push();let a=-(.3*normaSin(t/uMmaxTimeRange*90))+.8,_=.3*normaSin(t/uMmaxTimeRange*90)+.2,i=e*a,u=e*(.2+.4*b),f=e*_,m=u+e*(.1*b+.2);bezier(0,0,i,u,f,m,0,.96*e),push(),b<.5?(translate(0,.2*e),scale(.618)):scale(.618,1),b>.5&&stroke(o[l%nCol]),bezier(0,0,i,u,f,m,0,.96*e),pop(),push(),b<.5?(translate(0,e/4),scale(.36)):scale(.36,1),b>.75&&stroke($[l%nCol]),bezier(0,0,i,u,f,m,0,.96*e),pop(),b<.6&&(push(),b<.5?(translate(0,.275*e),scale(.2)):scale(.2,1),b>.75&&stroke($[l%nCol]),bezier(0,0,i,u,f,m,0,.96*e),pop(),push(),b<.5?(translate(0,.295*e),scale(.1)):scale(.1,1),b>.75&&stroke($[l%nCol]),bezier(0,0,i,u,f,m,0,.96*e),pop()),pop()}function blob3($,o,l,n,e=200,b,t){stroke($[l%nCol]);let a=(.1+1.3*b)*e,_=(.1+b)*e,i=.5*e;push(),rotateY(25*n),bezier(0,0,a,0,_,i,0,e);let u=normaSin((gR+t)/uMmaxTimeRange*90);translate(0,.19*e),scale(.182*u+.2,.182*u+.2,1*u),bezier(0,0,a,0,_,i,0,e),pop()}function blob4($,o,l,n,e=200,b=.2,t){stroke($[l%nCol]);let a=e*(.33*b+.3),_=a/4,i=a/3,u=a/1;push(),bezier(0,0,a,_,i,u,0,e),push(),scale(.618-.15*sin(t/uMmaxTimeRange*90),.618-.15*sin(t/uMmaxTimeRange*90),1),stroke(o[l%nCol]),bezier(0,0,a,_,i,u,0,e),pop(),translate(0,e*(.618-.15*sin(t/uMmaxTimeRange*90))),scale(.2,.382+.15*sin(t/uMmaxTimeRange*90),1),stroke(o[(l+1)%nCol]),bezier(0,0,a,_,i,u,0,e),pop()}function normaSin($){return sin($)/2+.5}function blob5($,o,l,n,e=200,b=.2,t){noiseSeed(1);for(let a=0;a<3;a++){stroke(0==a?$[l%nCol]:o[l%nCol]);let _=normaSin(max(0,t-(randomMonth=int(12*b)))/uMmaxTimeRange*90),i=_*e*(.6+.2*_),u=a*(_*e)*.01,f=i+.118*e+_*e*.22*a,m=u+e/8,g=.8*e-_*e*.5,h=(u+e/8+e)/2;bezier(i,u,f,m,g,h,0,e)}}function blob7($,o,l,n=200,e){push(),rotateY(20*l);let b=1.8,t=1;0==e?(b=.88,t=1.4):(5==e||e>=9)&&(b=1,t=1.5),1!=t?(push(),translate(0,n/2),bifolium(n,b,t),pop()):bifolium(n,b,t),pop()}function bifolium($,o,l){beginShape();for(let n=0;n<90;n+=.2)vertex(x=(r=$*o*pow(sin(n),.618)*cos(pow(n,l)))*sin(n),y=r*cos(n));endShape()}function drawEarth($,o,l){push();let[n,e]=l;if(blendMode(BLEND),"moor"==$){beginShape(),noStroke(),fill(n),vertex(-s*(9/16)/2,o-s/2),vertex(s*(9/16)/2,o-s/2),fill(e),vertex(s*(9/16)/2,o-s/2+s/28),vertex(-s*(9/16)/2,o-s/2+s/28),endShape(CLOSE),beginShape();for(let b=0;b<11;b++){fill(base);let t=o-s/2-(1.6*normaSin(frameCount/2%180)+1)*abs(b-5)**2;vertex(lerp(-s*(9/16)/2,s*(9/16)/2,b/10),t+s/28)}vertex(s*(9/16)/2,o-s/2),vertex(-s*(9/16)/2,o-s/2),endShape(CLOSE)}else if("mountain"==$){beginShape(),noStroke();for(let a=0;a<11;a++){fill(n);let _=max(o-s/2+s/32+s/32*normaSin(frameCount/2%180),o-s/2+s/32+s/32*normaSin(frameCount/8%180)+2*abs(a-5)**2);vertex(lerp(-s*(9/16)/2,s*(9/16)/2,a/10),_)}fill(e),vertex(s*(9/16)/2,.6*s),vertex(-s*(9/16)/2,.6*s),endShape()}pop()}function drawDome($,o,l,n){if(angAdj=l<.8?sin((uD+n)/(uDmaxTimeRange+uHmaxTimeRange)*90):sin(uD/uDmaxTimeRange*90),!("slice"==o&"ichi"!=$))return[-90*l,span=constrain(180-80*angAdj,5,178),rot=180];{let e=100*l+80;return[-60+40*l,span=constrain(e+(179-e)*angAdj,5,178),rot=180]}}function rand_choice($,o){return $[idx=Math.floor(0+($.length-1+1-0)*o)]}function selectBlob($,o,l){if("ichi"==$)blobs2=[rand_choice(blobs=[blob1,blob2],gR)];else if("fountain"==$){blobs=[blob0,blob1,blob2,blob3,blob4,blob5,blob7],blobs2=[];for(let n=0;n<l;n++)blobs2.push(rand_choice(blobs,o[n]))}else if("duo"==$||"companion"==$&&2==l)blobs2=rand_choice([[blob2,blob0],[blob4,blob0],[blob5,blob0],[blob1,blob1],[blob1,blob3],[blob1,blob4],[blob1,blob5],[blob2,blob2],[blob2,blob3],[blob2,blob4],[blob2,blob5],[blob3,blob2],[blob3,blob3],[blob3,blob4],[blob3,blob5],[blob5,blob1],[blob5,blob2],[blob5,blob3],[blob5,blob5],],gR);else if("companion"==$)blobs2=[rand_choice(blobs=[blob1,blob2,blob4],gR)];else{blobs2=[];for(let e=0;e<7;e++)blobs2.push(rand_choice([blob1,blob2,blob3,blob4,blob5],o[e]))}return blobs2}function drawPal($,o,l,n){return[pal=cubeHelixPal(n=10,abs($-(colGap=1==o?15:gR<.46?map(gR,0,1,20,36):gR<.6?120:180)*l)%360,-.35,.82,.7,[.28,.8],.5),innerPal=cubeHelixPal(n,abs($-colGap*l+180)%360,-.35,.8,.7,[.28,.8],.5)]}function cubeHelixPal($,o,l,n,e,b,t){let a=[];for(let _=0;_<$;_++)o-=2*_,a.push(color((c=cubeHelix(o,l,n,e,b,t))[0],c[1],c[2]));return a}function cubeHelix($,o,l,n,e,b){$=void 0!==$?$:300,o=void 0!==o?o:-1.5,l=void 0!==l?l:1,n=void 0!==n?n:1;let t=(e=void 0!==e?e:[0,1])[1]-e[0],a=2*Math.PI*($/360+o*b),_=Math.pow(e[0]+t*b,n),i=l*_*(1-_)/2,u=_+i*(-.14861*Math.cos(a)+1.78277*Math.sin(a)),f=_+i*(-.29227*Math.cos(a)-.90649*Math.sin(a)),m=_+i*(1.97294*Math.cos(a));return u=Math.floor(255*Math.max(0,Math.min(1,u))),f=Math.floor(255*Math.max(0,Math.min(1,f))),m=Math.floor(255*Math.max(0,Math.min(1,m))),[u,f,m]}function wRand($,o){let l,n=0;for(l in $)if(o<=(n+=$[l]))return l}function scaleArray($){for(var o=Math.min.apply(null,$),l=Math.max.apply(null,$),n=[],e=0;e<$.length;e++)n[e]=($[e]-o)/(l-o+1e-7);return n}function windowResized(){resizeCanvas((s=min(windowWidth*(16/9),windowHeight))*(9/16),s),redraw()}function keyTyped(){text=tokenData.hash,"s"===key?saveCanvas("sketch_",text+".png"):"w"===key&&(resizeCanvas((s=7680)/16*9,s),redraw(),saveCanvas("sketch_big.png"))}
p5.disableFriendlyErrors=!0;const gl=document.createElement("canvas").getContext("webgl2"),qPrms=new URLSearchParams(window.location.search);qPrms.get("h")&&(tokenData.hash=qPrms.get("h"));let cNSz=420,cNSp=1,cNDr=45,cNRg=1,pSzRg=1,pSzSp=.01,wgl=2;gl||(wgl=1),p5.RendererGL.prototype._initContext=function(){try{if(this.drawingContext=this.canvas.getContext("webgl2",this._pInst._glAttributes)||this.canvas.getContext("experimental-webgl",this._pInst._glAttributes),null===this.drawingContext)throw new Error("Error creating webgl context");{const e=this.drawingContext;e.enable(e.DEPTH_TEST),e.depthFunc(e.LEQUAL),e.viewport(0,0,e.drawingBufferWidth,e.drawingBufferHeight),this._viewport=this.drawingContext.getParameter(this.drawingContext.VIEWPORT)}}catch(e){throw e}},qPrms.get("clrSize")&&(cNSz=qPrms.get("clrSize")),qPrms.get("clrSpeed")&&(cNSp=qPrms.get("clrSpeed")),qPrms.get("clrDir")&&(cNDr=qPrms.get("clrDir")),qPrms.get("clrRange")&&(cNRg=qPrms.get("clrRange")),qPrms.get("petalSizeRange")&&(pSzRg=qPrms.get("petalSizeRange")),qPrms.get("petalSizeSpeed")&&(pSzSp=qPrms.get("petalSizeSpeed"));const PHI=(1+Math.sqrt(5))/2,hashPairs=[];for(let e=0;e<32;e++)hashPairs.push(tokenData.hash.slice(2+2*e,4+2*e));const dcP=hashPairs.map((e=>parseInt(e,16)));fl=e=>Math.floor(e),sq=e=>Math.sqrt(e),ab=e=>Math.abs(e);const seed=parseInt(tokenData.hash.slice(2,10),16);function easeOutExpo(e){return 1===e?1:1-Math.pow(2,-10*e)}function easeInExpo(e){return 0===e?0:Math.pow(2,10*e-10)}function easeInQuad(e){return e*e}function easeInCubic(e){return e*e*e}function easeOutCubic(e){return 1-Math.pow(1-e,3)}function easeInOutCubic(e){return e<.5?4*e*e*e:1-Math.pow(-2*e+2,3)/2}class Random{constructor(e){this.useA=!1;let t=function(t){let r=e,n=parseInt(t.substr(8,16),16),s=parseInt(t.substr(16,24),16),a=parseInt(t.substr(24,32),16);return function(){r|=0,n|=0,s|=0,a|=0;let e=(r+n|0)+a|0;return a=a+1|0,r=n^n>>>9,n=s+(s<<3)|0,s=s<<21|s>>>11,s=s+e|0,(e>>>0)/4294967296}};this.prngA=new t(tokenData.hash.substr(2,32)),this.prngB=new t(tokenData.hash.substr(34,32));for(let e=0;e<1e6;e+=2)this.prngA(),this.prngB()}r_dec(){return this.useA=!this.useA,this.useA?this.prngA():this.prngB()}r_num(e,t){return e+(t-e)*this.r_dec()}r_int(e,t){return Math.floor(this.r_num(e,t+1))}r_bool(e){return this.r_dec()<e}r_choice(e){return e[this.r_int(0,e.length-1)]}}let ww,wh,un,mnr,myr,mc,bas,lnz,shCnvs,shdr,msk,mlt,bgc,bgCol,R=new Random(seed),S=new Random(3*seed),N=new Random(seed-9),palette=swatches[dcP[2]%swatches.length],jColors=JSON.parse(JSON.stringify(palette.colors)),clrs=hsbPal([...jColors]),clrStl="Full",clrOrd=dcP[26]%5>1?"Spiral":"Rings";cNSz=75+3500*dcP[11]/255,cNSp=2+16*dcP[12]/255,cNDr=359*dcP[13]/255,cNRg=4.25*dcP[14]/255-.25,pSzRg=.2+4.8*easeInExpo(dcP[15]/255),pSzSp=.01+6.99*easeInExpo(dcP[16]/255);let leaf=leaves[dcP[4]%leaves.length];const GaussianBlur="\n\t#ifndef PI\n\t#define PI 3.14159265359\n\t#endif\n\n\t// Gaussian function\n\tfloat gaussian(float x, float sigma) {\n\t\treturn exp(-(x*x)/(2.*sigma*sigma))/(sqrt(2.*PI)*sigma);\n\t}\n\t\n\n\t// Gaussian blur\n\tvec3 GaussianBlur(vec2 uv, sampler2D img, float radius, float sigma, vec2 texelSize) {\n\t\tvec3 color = vec3(0.);\n\t\tfloat sum = 0.;\n\n vec2 halfTexelSz = texelSize * 4.0;\n\n\t\tfor (float x = -radius; x <= radius; x++) {\n\t\t\tfor (float y = -radius; y <= radius; y++) {\n\t\t\t\tfloat weight = gaussian(length(vec2(x, y)), sigma);\n\t\t\t\tcolor += texture(img, (uv + vec2(x, y) * halfTexelSz)).xyz * weight;\n\t\t\t\tsum += weight;\n\t\t\t}\n\t\t}\n\t\treturn color/sum;\n\t}\n\t\n",frg=`#version 300 es\nprecision mediump float;\n\nuniform vec2 iResolution;\nuniform float iPixelDensity;\nuniform sampler2D iCanvas;\nuniform sampler2D iGlow;\nuniform sampler2D iMask;\nuniform float iRadius;\nuniform float iSigma;\n\n${GaussianBlur}\n\nin vec2 vTexCoord;\nout vec4 fragColor;\n\nvoid main() {\n vec2 uv = vec2(vTexCoord.x, 1.0-vTexCoord.y);\n vec2 texelSize = 1./(iResolution.xy*iPixelDensity);\n vec3 texMask = texture(iMask, uv).rgb;\n\n vec3 color = GaussianBlur(\n uv, iCanvas,\n iRadius, iSigma, texelSize\n );\n\n vec3 glow = GaussianBlur(\n uv, iGlow,\n iRadius/2., iSigma/2., texelSize\n );\n\n //Color sample and weight sums for weighted average\n vec4 color_sum = vec4(0);\n vec4 weight_sum = vec4(0);\n\n for(float i = 0.0; i<=1.0; i+=1.0/12.0) {\n //Sample texture coordinates with offset (-0.5 to +0.5)\n vec2 coord = uv + (i-0.5) * 0.0075;\n\n //Sample texture at coordinates\n vec4 color = texture(iGlow, coord);\n\n //Get separate weight values for each channel\n //R ranges from 0 to 1, G from 0 to 1 to 0 and B from 1 to 0\n vec4 weight = vec4(i, 1.0 - abs(i*2.0 - 1.0), 1.0 - i, 0.5);\n \n //Add color (squared for gamma) with weight factors\n color_sum += color * color * weight;\n //Add weight totals for averaging\n weight_sum += weight;\n }\n\n vec3 abglow = vec3(glow.r*uv.x,glow.g,glow.b*uv.y);\n vec4 abrr = sqrt(color_sum*2.2 / weight_sum);\n vec3 suma = (color + glow + abrr.rgb*3.0)/3.0;\n\n fragColor = vec4(vec3(suma), texMask.g*0.64);\n //fragColor = abrr;\n}\n`,vrt="#version 300 es\n\n\tin vec3 aPosition;\n\tin vec2 aTexCoord;\n\n\tout vec2 vTexCoord;\n\n\tvoid main() {\n\t\tvTexCoord = aTexCoord;\n\t\tgl_Position = vec4(aPosition.xy*2.-1., aPosition.z, 1.0);\n\t}\n";function setup(){colorMode(HSL),ww=innerWidth,wh=innerHeight,mnr=ww<wh?ww:wh,myr=ww>wh?ww:wh,un=myr/100,mc=createCanvas(ww,wh),lnz=createGraphics(ww,wh),bas=createGraphics(ww,wh),msk=createGraphics(ww,wh),mlt=createGraphics(ww,wh),pixelDensity(2),lnz.pixelDensity(2),msk.pixelDensity(2),bas.pixelDensity(2),mlt.pixelDensity(2),noiseSeed(seed),lnz.translate(ww/2,wh/2),2==wgl&&(shCnvs=createGraphics(ww,wh,WEBGL),shCnvs.pixelDensity(1),shCnvs.translate(ww/2,wh/2),shCnvs.rectMode(CENTER),shdr=shCnvs.createShader(vrt,frg)),lnz.rectMode(CENTER),lnz.imageMode(CENTER),lnz.colorMode(HSL),lnz.strokeJoin(ROUND),bas.colorMode(HSL),bas.strokeJoin(ROUND),msk.colorMode(HSL),msk.strokeJoin(ROUND),mlt.colorMode(HSL),mlt.strokeJoin(ROUND),mlt.rectMode(CENTER),bgc=clrs[dcP[17]%clrs.length],bgCol=color(bgc.h,bgc.s,bgc.l),background(bgCol),noFill(),stroke(bgCol),translate(ww/2,wh/2);let e=1.5*myr/200;strokeWeight(.55*e);for(let t=0;t<200;t++){stroke(0,t/250),circle(0,0,t*e)}}function draw(){translate(ww/2,wh/2),imageMode(CENTER),bas.push(),bas.translate(ww/2,wh/2),bas.imageMode(CENTER);let e=frameCount<1200?frameCount:1200,t=frameCount<e?.08:.08-(frameCount-e)/1200;bgCol.setAlpha(t/10),bas.background(bgCol),bgCol.setAlpha(t),lnz.background(bgCol),2==wgl&&shCnvs.background(bgCol),msk.push(),msk.background(20),msk.translate(ww/2,wh/2),msk.imageMode(CENTER),mlt.push(),mlt.background(0),mlt.translate(ww/2,wh/2),mlt.imageMode(CENTER);for(let t=0;t<e;t++){let r=PHI*PI*2*t+(dcP[5]/128-1)*frameCount/2e3,n=myr/(1e6+5*frameCount)-myr/200+lerp(e*myr/(800+4*t),0,easeInQuad(t/e)),s=n*cos(r),a=n*sin(r),o=frameCount*(cos(PI*cNDr/180)*cNSp*.001),l=frameCount*(sin(PI*cNDr/180)*cNSp*.001),i=noise(s/cNSz-o,a/cNSz+l)*cNRg,c=noise(46*s/cNSz-o/2,46*a/cNSz+l/2)*cNRg*1.6,m=n/myr<.5?8-8*easeOutExpo(n/myr):0,h=noise(s/80+.01*frameCount*pSzSp,a/80+.01*frameCount*pSzSp)*m**1.05*pSzRg,u=myr/1024+myr/8*(n/myr)*(1+n**1.2/myr)*(.8+h);msk.push(),msk.translate(s,a),msk.rotate(r),msk.strokeWeight(myr/60*(n/myr)),msk.stroke(100,.5),msk.fill(255),drawMask(.006*u,leaf,n/myr),msk.pop(),mlt.push(),mlt.blendMode(BLEND),mlt.translate(s,a),mlt.rotate(r+.05);let g,d,p,w,f,b=(frameCount/60+int(n/2)+90*i+90*sin(r-frameCount/270))%360;mlt.strokeWeight(myr/32*easeInQuad(n/myr)*i),mlt.stroke(b,100,20+40*h,.5),mlt.fill(0),drawLip(.006*u,leaf,n/myr),mlt.rotate(-.1),mlt.translate(myr/600,i*myr/800),mlt.fill(0,.1),mlt.blendMode(SCREEN),drawLip(.006*u,leaf,n/myr),mlt.rotate(.05),mlt.stroke(b,50,60+50*h,.7),mlt.strokeWeight(myr/64*easeInQuad(n/myr)*i),mlt.translate(i*myr/900,-myr/1200),drawLip(.0059*u,leaf,n/myr),mlt.blendMode(BLEND),mlt.stroke(0),mlt.strokeWeight(i*(myr/30)*easeInQuad(n/myr)),mlt.rotate(h/10-.08),mlt.translate(-myr/400,i*myr/800),drawLip(.0062*u,leaf,n/myr),mlt.pop(),bas.push(),bas.translate(s,a),bas.rotate(r),bas.noStroke();let v=30*cos(r-PI/4)*(n/myr),C=15*cos(r-PI/4)*(1-n/(.5*myr))+5*i-10;if("Spiral"==clrOrd)w=clrs[t%clrs.length],g=w.h,d=w.s+v,p=w.l+C,f=color(g,d,p);else{let e=40*n/myr-frameCount/60%clrs.length-fl(40*n/myr-frameCount/60%clrs.length),t=clrs.length-fl(40*n/myr-frameCount/60%clrs.length)%clrs.length-1;t=t>=clrs.length?t-clrs.length:t,w=clrs[t];let r=t<clrs.length-1?clrs[t+1]:clrs[0];g=w.h,d=w.s+v,p=w.l+C,f=color(g,d,p);let s=color(r.h,r.s+v,r.l+C);e<.2&&e>0&&(bas.colorMode(RGB),f=bas.lerpColor(s,f,5*e),bas.colorMode(HSL))}bas.fill(f),bas.stroke(g,d,.95*p,.2),bas.strokeWeight(myr/120*(n/myr)),drawPetal(.006*u,leaf,n/myr),bas.noFill(),bas.stroke(g,d,.9*p,.2),bas.strokeWeight(myr/240*(n/myr)),drawPetal(.006*u,leaf,n/myr),bas.pop(),lnz.push(),lnz.translate(s,a),lnz.rotate(r);let y=(frameCount/60+int(n/2)+90*i+90*sin(r-frameCount/270))%360,S=65*easeInOutCubic(cos(2*r+noise(frameCount/480)*PI*4)/2+.2)*(1-n/(.5*myr))+3*easeOutCubic(c);bgc.l>45?lnz.fill(y,50+v,.4*S):lnz.fill(0),lnz.strokeWeight(myr/900+n/20),lnz.stroke(y,50+v,S,.3),drawGlow(.005*u,leaf,n/myr),lnz.noFill(),lnz.strokeWeight(myr/2100+n/40),lnz.stroke(y,50+v,S,.3),drawGlow(.005*u,leaf,n/myr),lnz.strokeWeight(myr/4800+n/120),lnz.stroke(y,50+v,S,.3),drawGlow(.005*u,leaf,n/myr),lnz.pop()}2==wgl&&(shCnvs.shader(shdr),shdr.setUniform("iResolution",[width,height]),shdr.setUniform("iPixelDensity",pixelDensity()),shdr.setUniform("iCanvas",lnz),shdr.setUniform("iBas",bas),shdr.setUniform("iMask",msk),shdr.setUniform("iGlow",mlt),shdr.setUniform("iRadius",16),shdr.setUniform("iSigma",4),shdr.setUniform("iTime",.1*frameCount),shCnvs.rect(0,0,width,height)),bas.pop(),msk.pop(),mlt.pop(),blendMode(BLEND),bgc.l,bas.blendMode(SCREEN),image(bas,0,0),bas.blendMode(BLEND),2==wgl?(blendMode(OVERLAY),image(shCnvs,0,0,width,height)):image(bas,0,0,width,height),blendMode(BLEND)}function drawPetal(e,t,r){let n=lerp(t.bct,t.mct,r);bas.curveTightness(n),bas.rotate(PI/2),bas.beginShape();for(let n=1;n<t.hja.length;n++){let s=lerp(t.pts[n].x,t.hja[n].x,r),a=lerp(t.pts[n].y,t.hja[n].y,r);bas.curveVertex(s*e,a*e)}bas.endShape(CLOSE),bas.rotate(-PI/2)}function drawMask(e,t,r){let n=lerp(t.bct,t.mct,r);msk.curveTightness(n),msk.rotate(PI/2),msk.beginShape();for(let n=1;n<t.hja.length;n++){let s=lerp(t.pts[n].x,t.hja[n].x,r),a=lerp(t.pts[n].y,t.hja[n].y,r);msk.curveVertex(s*e,a*e)}msk.endShape(CLOSE),msk.rotate(-PI/2)}function drawLip(e,t,r){let n=lerp(t.bct,t.mct,r);mlt.curveTightness(n),mlt.rotate(PI/2),mlt.beginShape();for(let n=1;n<t.hja.length;n++){let s=lerp(t.pts[n].x,t.hja[n].x,r),a=lerp(t.pts[n].y,t.hja[n].y,r);mlt.curveVertex(s*e,a*e)}mlt.endShape(CLOSE),mlt.rotate(-PI/2)}function drawGlow(e,t,r){let n=lerp(t.bct,t.mct,r);lnz.curveTightness(n),lnz.rotate(PI/2),lnz.beginShape();for(let n=1;n<t.hja.length;n++){let s=lerp(t.pts[n].x,t.hja[n].x,r),a=lerp(t.pts[n].y,t.hja[n].y,r);lnz.curveVertex(s*e,a*e)}lnz.endShape(CLOSE),lnz.rotate(-PI/2)}function hsbPal(e){let t=[];for(c of e){let e=toHSL(c);t.push(e)}return t}function toHSL(e){let t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e),r=parseInt(t[1],16),n=parseInt(t[2],16),s=parseInt(t[3],16);r/=255,n/=255,s/=255;let a,o,l=Math.max(r,n,s),i=Math.min(r,n,s),c=(l+i)/2;if(l==i)a=o=0;else{let e=l-i;switch(o=c>.5?e/(2-l-i):e/(l+i),l){case r:a=(n-s)/e+(n<s?6:0);break;case n:a=(s-r)/e+2;break;case s:a=(r-n)/e+4;break}a/=6}return a=Math.round(360*a),o=Math.round(100*o),c=Math.round(100*c),{h:a,s:o,l:c}}function mouseClicked(){}function touchEnded(){}keyPressed=()=>{"s"===key&&save(tokenData.hash+"-"+frameCount),"p"===key&&noLoop()};
Growth: Threads artworks are part of the Future Reflections generative art collection presented by Shiseido. The collection consists of 1,872 unique generative artworks created in partnership with leading contemporary artists, powered by Art Blocks Engine. Celebrating the parallel processes of generative, code-based art creation and the art and science of beauty product innovation, Future Reflections draws inspiration from Shiseido’s 150 years of Japanese heritage - past, present, and future - along with nutrient-rich ingredients in the brand’s Future Solution LX skincare collection. The Growth: Threads artworks were created by Robert’s sophisticated growth algorithm, and emulate the growth of various seeds, specifically the material essence of the Legendary Enmei herb. Their rich use of iridescent color is juxtaposed with a background of patterns inspired by Japanese embroidery designed and generated by the artist.
var s, layout, dome, blobs, blobs2, dark, light, base, today, uH, uD, uM, fastForwardRate, randomMonth, colGap, gR, version = 3.8, nBlob = 6, nCol = 8, uDmaxTimeRange = 31, uMmaxTimeRange = 12, uHmaxTimeRange = 24, rarr = [], rarro = []; function calculateFeatures($) { let o = new (class o { constructor() { this.useA = !1; let o = function ($) { let o = parseInt($.substr(0, 8), 16), l = parseInt($.substr(8, 8), 16), n = parseInt($.substr(16, 8), 16), e = parseInt($.substr(24, 8), 16); return function () { n |= 0; let $ = ((((o |= 0) + (l |= 0)) | 0) + (e |= 0)) | 0; return ( (e = (e + 1) | 0), (o = l ^ (l >>> 9)), (l = (n + (n << 3)) | 0), (n = ((n = (n << 21) | (n >>> 11)) + $) | 0), ($ >>> 0) / 4294967296 ); }; }; (this.prngA = new o($.hash.substr(2, 32))), (this.prngB = new o($.hash.substr(34, 32))); for (let l = 0; l < 1e6; l += 2) this.prngA(), this.prngB(); } random_dec() { return (this.useA = !this.useA), this.useA ? this.prngA() : this.prngB(); } random_int($, o) { return Math.floor($ + (o + 1 - $) * this.random_dec()); } random_choice($) { return $[this.random_int(0, $.length - 1)]; } wRand($) { let o, l = 0, n = this.random_dec(); for (o in $) if (n <= (l += $[o])) return o; } })(); var l = {}; return ( (l.layout = o.wRand({ ichi: 0.02, companion: 0.08, duo: 0.2, fountain: 0.7, })), (l.nBlob = "ichi" == l.layout ? 1 : "companion" == l.layout ? o.wRand({ 1: 0.7, 2: 0.3 }) : "duo" == l.layout ? 2 : o.random_int(3, 7)), (l.monotone = o.wRand({ 0: 0, 1: 1 })), (l.bg = -1 != ["ichi", "companion", "duo"].indexOf(l.layout) ? "mountain" : o.random_choice(["moor", "mountain"])), (l.bgCol = -1 != ["ichi", "companion"].indexOf(l.layout) ? ["#222", "#fff", "#111"] : o.random_choice([ ["#1E0E2D", "#07f49e", "#111"], ["#111", "#fff", "#111"], ["#00113D", "#edb144", "#051132"], ])), l ); } var features = calculateFeatures(tokenData); function setup() { createCanvas( (s = min(windowWidth * (16 / 9), windowHeight)) * (9 / 16), s, WEBGL ); for (let $ = 0; $ < nBlob + 1; $++) { let o = tokenData.hash.slice(2 * $ + 2, 2 * $ + 4); rarro.push((parseInt(o, 16) % 100) / 100); } (gR = (rarr = scaleArray(rarro))[0]), ([dark, light, base] = features.bgCol), (nBlob = int(features.nBlob)), (blobs2 = selectBlob(features.layout, rarr, nBlob)); } function draw() { background(base), angleMode(DEGREES), blendMode(ADD); let $ = new Date(); (uD = $.getDate()), (uH = $.getHours()), (uM = $.getMonth()), push(); let o = (0.7 * s) / (0.6 + nBlob), l = 0.15 * s + o * nBlob; (firstBlobCol = drawPal( (initAng = round(300 * gR) % 360), (monotone = int(features.monotone)), 0, nCol )[0][0]), drawEarth(features.bg, l, (tones = [dark, firstBlobCol])), fill("#208bff00"), "companion" == features.layout ? asawa0(nBlob, blobs2, monotone, rarr, uM, o) : asawa(nBlob, blobs2, monotone, rarr, uM, o), pop(), (text = tokenData.hash); } function asawa0($, o, l, n, e, b) { push(), rotateY(30 * gR), gR < 0.5 ? rotateY(10 * e) : rotateY(-(10 * e)), (j = 0), push(), asawa($, o, l, n, e, b), pop(), (b /= 5), push(); let t = gR < 0.1 || 2 == $ ? s / 5 : s / 10; translate(-s / 5, t), asawa($, o, features.monotone, n, e, b), pop(), push(); let a = gR < 0.1 || 2 == $ ? 0 : s / 5; translate((2 * s) / 5, a), asawa($, o, features.monotone, n, e, b), pop(), pop(); } function asawa($, o, l, n, e, b) { push(), translate(0, -s / 2); let t = 0.15 * s; for (let a = 0; a < $; a++) { let _ = n[a] < 0.15 ? 30 * e : n[a] < 0.35 ? -30 * e : 0; [pal, innerPal] = drawPal(initAng + _, l, a, nCol); let i = wRand({ slice: 0.75, full: 0.25 }, n[a]), u = t + b * a; if ((push(), isPolarBlob(o[a]))) blobbyBifoliumHeart(o, a, 0, u, pal, innerPal, b, e); else for (let f = 0; f < 2; f++) blobby( f + 0, u, o, a, pal, innerPal, b, (angIncre = 3), (dome = i), n[a], e ); pop(); } } function blobbyBifoliumHeart($, o, l, n, e, b, t, a) { push(), translate(l, n), (blobi = $[o]), o > 1 && ($[o - 1] == blob0 || $[o - 1] == blob3) && (a = 0); for (let _ = 30; _ < 120; _ += 2) strokeWeight((sw = selectStroke(_))), push(), rotateY(-(2 * _)), stroke(200, 200, 0), blobi(e, b, o, t, a), pop(); for (let i = -60; i < 20; i += 2) strokeWeight((sw = selectStroke(i))), push(), rotateY(2 * i), stroke(e[0]), blobi(e, b, o, t, a), pop(); pop(); } function blobby($, o, l, n, e, b, t, a, _, i, u) { ([ang, span, rot] = drawDome(features.layout, _, i, uH)), (angLst = [ang, ang + rot]); let f = Array(nCol).fill(color(200, 200, 0)); pals = gR < 0.09 ? [e, f] : [e, e]; let m = 2; isPolarBlob(l[n]) && ((rot = 0), (m = 1), (span = 90)); for (let h = 0; h < m; h++) push(), rotateY(angLst[h]), blobLayer( $ + (xdispAdj = i < 0.25 && l.length > 2 ? t / 16 : 0), o, l, n, pals[h], b, t, angLst[h], span, a, i, u ), pop(); } function isPolarBlob($) { return $ == blob7; } function selectStroke($) { return ( (sw = $ % 5 < 2 ? 0.6 : 0.1618), s > 1600 && (sw *= map(s, 800, 8e3, 1, 6)), sw ); } function blobLayer($, o, l, n, e, b, t, a = 0, _ = 180, i = 2, u, f) { (f = int(f)), push(), translate($, o); let m = max(0, f - (randomMonth = int(12 * u))), h = 5 + 5 * sin(((m + uD / uDmaxTimeRange / 2 + gR / 2) / uMmaxTimeRange) * 90); rotateX( 0 == n && l.length > 1 ? 0 : u < 0.1 && 0 != n ? h : u < 0.7 ? -h : 0 ); for (let d = 0; d < _; d += i) stroke(e[d % nCol]), strokeWeight((sw = selectStroke(d))), push(), rotateY(d), "ichi" == layout && scale(2.88), (u < 0.3 && !isPolarBlob(blobs2[n]) && l.length > 3) || ("duo" == features.layout && 0 == n) || (3 == l.length && 0 == n) ? (push(), translate(0, t, 0), 2 == l.length && 0 == n ? scale(0.86, -0.86, 1) : scale(1, -1, 1), blobs2[n](e, b, d, n, t, u, f), pop()) : blobs2[n](e, b, d, n, t, u, f), pop(); pop(); } function blob0($, o, l, n, e, b = 0.2, t) { stroke($[l % nCol]), push(), rotateY(20 * n); let a = 2.68 * (e *= 0.8), _ = 1.88 * e, i = 0.03 * e, u = 1.43 * e; bezier(0, 0, a, _, i, u, 0, e), b < 0.2 && n != nBlob - 1 ? scale(0.618, 0.9) : (translate(0, 0.3 * e), scale(0.618)), b < 0.5 && stroke(o[l % nCol]), bezier(0, 0, a, _, i, u, 0, e), b > 0.25 && (scale(0.5), b < 0.5 && stroke($[l % nCol]), translate(0, e / 2), bezier(0, 0, a, _, i, u, 0, e)), pop(); } function blob1($, o, l, n, e = 200, b, t) { stroke($[l % nCol]); let a = (0.3 + 0.6 * b) * e, _ = b * e * 1.1; bezier(0, 0, 0, 0, a, _, 0, e); let i = normaSin((t / uMmaxTimeRange) * 90), u = i * e * 0.6, f = i * e * 0.1; (a = f + i * e * 0.2), (_ = u + 0.3 * i * e), push(), stroke(o[l % nCol]), scale(0.5, 0.3 + 0.6 * b, 1), bezier(0, u, f, u, a, _, 0, e), pop(); } function blob2($, o, l, n, e = 200, b, t) { stroke($[l % nCol]), push(); let a = -(0.3 * normaSin((t / uMmaxTimeRange) * 90)) + 0.8, _ = 0.3 * normaSin((t / uMmaxTimeRange) * 90) + 0.2, i = e * a, u = e * (0.2 + 0.4 * b), f = e * _, m = u + e * (0.1 * b + 0.2); bezier(0, 0, i, u, f, m, 0, 0.96 * e), push(), b < 0.5 ? (translate(0, 0.2 * e), scale(0.618)) : scale(0.618, 1), b > 0.5 && stroke(o[l % nCol]), bezier(0, 0, i, u, f, m, 0, 0.96 * e), pop(), push(), b < 0.5 ? (translate(0, e / 4), scale(0.36)) : scale(0.36, 1), b > 0.75 && stroke($[l % nCol]), bezier(0, 0, i, u, f, m, 0, 0.96 * e), pop(), b < 0.6 && (push(), b < 0.5 ? (translate(0, 0.275 * e), scale(0.2)) : scale(0.2, 1), b > 0.75 && stroke($[l % nCol]), bezier(0, 0, i, u, f, m, 0, 0.96 * e), pop(), push(), b < 0.5 ? (translate(0, 0.295 * e), scale(0.1)) : scale(0.1, 1), b > 0.75 && stroke($[l % nCol]), bezier(0, 0, i, u, f, m, 0, 0.96 * e), pop()), pop(); } function blob3($, o, l, n, e = 200, b, t) { stroke($[l % nCol]); let a = (0.1 + 1.3 * b) * e, _ = (0.1 + b) * e, i = 0.5 * e; push(), rotateY(25 * n), bezier(0, 0, a, 0, _, i, 0, e); let u = normaSin(((gR + t) / uMmaxTimeRange) * 90); translate(0, 0.19 * e), scale(0.182 * u + 0.2, 0.182 * u + 0.2, 1 * u), bezier(0, 0, a, 0, _, i, 0, e), pop(); } function blob4($, o, l, n, e = 200, b = 0.2, t) { stroke($[l % nCol]); let a = e * (0.33 * b + 0.3), _ = a / 4, i = a / 3, u = a / 1; push(), bezier(0, 0, a, _, i, u, 0, e), push(), scale( 0.618 - 0.15 * sin((t / uMmaxTimeRange) * 90), 0.618 - 0.15 * sin((t / uMmaxTimeRange) * 90), 1 ), stroke(o[l % nCol]), bezier(0, 0, a, _, i, u, 0, e), pop(), translate(0, e * (0.618 - 0.15 * sin((t / uMmaxTimeRange) * 90))), scale(0.2, 0.382 + 0.15 * sin((t / uMmaxTimeRange) * 90), 1), stroke(o[(l + 1) % nCol]), bezier(0, 0, a, _, i, u, 0, e), pop(); } function normaSin($) { return sin($) / 2 + 0.5; } function blob5($, o, l, n, e = 200, b = 0.2, t) { noiseSeed(1); for (let a = 0; a < 3; a++) { stroke(0 == a ? $[l % nCol] : o[l % nCol]); let _ = normaSin( (max(0, t - (randomMonth = int(12 * b))) / uMmaxTimeRange) * 90 ), i = _ * e * (0.6 + 0.2 * _), u = a * (_ * e) * 0.01, f = i + 0.118 * e + _ * e * 0.22 * a, m = u + e / 8, h = 0.8 * e - _ * e * 0.5, d = (u + e / 8 + e) / 2; bezier(i, u, f, m, h, d, 0, e); } } function blob7($, o, l, n = 200, e) { push(), rotateY(20 * l); let b = 1.8, t = 1; 0 == e ? ((b = 0.88), (t = 1.4)) : (5 == e || e >= 9) && ((b = 1), (t = 1.5)), 1 != t ? (push(), translate(0, n / 2), bifolium(n, b, t), pop()) : bifolium(n, b, t), pop(); } function bifolium($, o, l) { beginShape(); for (let n = 0; n < 90; n += 0.2) vertex( (x = (r = $ * o * pow(sin(n), 0.618) * cos(pow(n, l))) * sin(n)), (y = r * cos(n)) ); endShape(); } function drawEarth($, o, l) { push(); let [n, e] = l; if ((blendMode(BLEND), "moor" == $)) { beginShape(), noStroke(), fill(n), vertex((-s * (9 / 16)) / 2, o - s / 2), vertex((s * (9 / 16)) / 2, o - s / 2), fill(e), vertex((s * (9 / 16)) / 2, o - s / 2 + s / 28), vertex((-s * (9 / 16)) / 2, o - s / 2 + s / 28), endShape(CLOSE), beginShape(); for (let b = 0; b < 11; b++) { fill(base); let t = o - s / 2 - (1.6 * normaSin((frameCount / 2) % 180) + 1) * abs(b - 5) ** 2; vertex(lerp((-s * (9 / 16)) / 2, (s * (9 / 16)) / 2, b / 10), t + s / 28); } vertex((s * (9 / 16)) / 2, o - s / 2), vertex((-s * (9 / 16)) / 2, o - s / 2), endShape(CLOSE); } else if ("mountain" == $) { beginShape(), noStroke(); for (let a = 0; a < 11; a++) { fill(n); let _ = max( o - s / 2 + s / 32 + (s / 32) * normaSin((frameCount / 2) % 180), o - s / 2 + s / 32 + (s / 32) * normaSin((frameCount / 8) % 180) + 2 * abs(a - 5) ** 2 ); vertex(lerp((-s * (9 / 16)) / 2, (s * (9 / 16)) / 2, a / 10), _); } fill(e), vertex((s * (9 / 16)) / 2, 0.6 * s), vertex((-s * (9 / 16)) / 2, 0.6 * s), endShape(); } pop(); } function drawDome($, o, l, n) { if (!(("slice" == o) & ("ichi" != $))) return [ -90, (span = 180 - 60 * sin((n / uHmaxTimeRange) * 90)), (rot = 180), ]; { let e = 100 * l + 80; return [ -60 + 40 * l, (span = e + (179 - e) * sin((n / uHmaxTimeRange) * 90)), (rot = 180), ]; } } function rand_choice($, o) { return $[(idx = Math.floor(0 + ($.length - 1 + 1 - 0) * o))]; } function selectBlob($, o, l) { if ("ichi" == $) blobs2 = [rand_choice((blobs = [blob1, blob2]), gR)]; else if ("fountain" == $) { (blobs = [blob0, blob1, blob2, blob3, blob4, blob5, blob7]), (blobs2 = []); for (let n = 0; n < l; n++) blobs2.push(rand_choice(blobs, o[n])); } else if ("duo" == $ || ("companion" == $ && 2 == l)) blobs2 = rand_choice( [ [blob2, blob0], [blob4, blob0], [blob5, blob0], [blob1, blob1], [blob1, blob3], [blob1, blob4], [blob1, blob5], [blob2, blob2], [blob2, blob3], [blob2, blob4], [blob2, blob5], [blob3, blob2], [blob3, blob3], [blob3, blob4], [blob3, blob5], [blob5, blob1], [blob5, blob2], [blob5, blob3], [blob5, blob5], ], gR ); else if ("companion" == $) blobs2 = [rand_choice((blobs = [blob1, blob2, blob4]), gR)]; else { blobs2 = []; for (let e = 0; e < 7; e++) blobs2.push(rand_choice([blob1, blob2, blob3, blob4, blob5], o[e])); } return blobs2; } function drawPal($, o, l, n) { return [ (pal = cubeHelixPal( (n = 10), abs( $ - (colGap = 1 == o ? 15 : gR < 0.46 ? map(gR, 0, 1, 20, 36) : gR < 0.6 ? 120 : 180) * l ) % 360, -0.35, 0.82, 0.7, [0.28, 0.8], 0.5 )), (innerPal = cubeHelixPal( n, abs($ - colGap * l + 180) % 360, -0.35, 0.8, 0.7, [0.28, 0.8], 0.5 )), ]; } function cubeHelixPal($, o, l, n, e, b, t) { let a = []; for (let _ = 0; _ < $; _++) (o -= 2 * _), a.push(color((c = cubeHelix(o, l, n, e, b, t))[0], c[1], c[2])); return a; } function cubeHelix($, o, l, n, e, b) { ($ = void 0 !== $ ? $ : 300), (o = void 0 !== o ? o : -1.5), (l = void 0 !== l ? l : 1), (n = void 0 !== n ? n : 1); let t = (e = void 0 !== e ? e : [0, 1])[1] - e[0], a = 2 * Math.PI * ($ / 360 + o * b), _ = Math.pow(e[0] + t * b, n), i = (l * _ * (1 - _)) / 2, u = _ + i * (-0.14861 * Math.cos(a) + 1.78277 * Math.sin(a)), f = _ + i * (-0.29227 * Math.cos(a) - 0.90649 * Math.sin(a)), m = _ + i * (1.97294 * Math.cos(a)); return ( (u = Math.floor(255 * Math.max(0, Math.min(1, u)))), (f = Math.floor(255 * Math.max(0, Math.min(1, f)))), (m = Math.floor(255 * Math.max(0, Math.min(1, m)))), [u, f, m] ); } function wRand($, o) { let l, n = 0; for (l in $) if (o <= (n += $[l])) return l; } function scaleArray($) { for ( var o = Math.min.apply(null, $), l = Math.max.apply(null, $), n = [], e = 0; e < $.length; e++ ) n[e] = ($[e] - o) / (l - o + 1e-7); return n; } function windowResized() { resizeCanvas((s = min(windowWidth * (16 / 9), windowHeight)) * (9 / 16), s), redraw(); } function keyTyped() { (text = tokenData.hash), "s" === key ? saveCanvas("sketch_", text + ".png") : "w" === key && (resizeCanvas(((s = 7680) / 16) * 9, s), redraw(), saveCanvas("large_sketch.png")); }
Transcendence artworks are part of the Future Reflections generative art collection presented by Shiseido. The collection consists of 1,872 unique generative artworks created in partnership with leading contemporary artists, powered by Art Blocks Engine. Celebrating the parallel processes of generative, code-based art creation and the art and science of beauty product innovation, Future Reflections draws inspiration from Shiseido’s 150 years of Japanese heritage - past, present, and future - along with nutrient-rich ingredients in the brand’s Future Solution LX skincare collection. The Transcendence artworks draw inspiration from artist Ruth Asawa’s woven sculptures, seeds from various plants, and the curvature found in futuristic architecture. The artworks are dynamic, changing over time, and capture the raw vitality of life force and reflect on the serene and delicate meditative nature of interconnectedness.
let swatches=[{colors:["66ff6d","3add3a","2ebc2e","1ea51e","129112","087c08","006d00","005400","d9ff39","c9e525","b9c91f","a6ad17","9b9b10","898506","726c01","5b5400","9cffec","5ae5c0","48cca6","39b790","2ba079","208c65","136d48","055635"]},{colors:["cf69ff","22d3c6","8d41c4","22d3c6","5f2999","22d3c6","37156d","22d3c6","180644","22d3c6","180644","22d3c6","37156d","22d3c6","5f2999","22d3c6","8d41c4","22d3c6"]},{colors:["bbff00","45b4ff","bbff00","45b4ff","bbff00","45b4ff","bbff00","45b4ff","6cff8b","4638fc","6cff8b","4638fc","6cff8b","4638fc","6cff8b","4638fc","4affe9","158918","4affe9","158918","4affe9","158918","4affe9","158918"]},{colors:["8abfff","005e00","229bff","5e9e1b","0b6fff","65d800","0b6fff","cbed00","229bff","ffce00","5caeff","d88500","8abfff","776b00","d2e9ff","3b4900","e0e0e0","353535","e0e0e0","353535","e0e0e0","353535","e0e0e0","353535","a3a3a3","515151","a3a3a3","515151","a3a3a3","515151","a3a3a3","515151"]},{colors:["f4ff0d","005e00","f4ff0d","5e9e1b","f4ff0d","65d800","f4ff0d","cbed00","f4ff0d","ffce00","f4ff0d","d88500","f4ff0d","776b00","f4ff0d","3b4900"]},{colors:["0e033c","3bbb06","0e0942","60c902","090948","85d603","090e4e","ace405","091354","d1f106","09185a","faff08","091e5f","fbf10e","092465","f7e214","092c6b","f4d318","093571","f0c90c","093d77","ecbe00","09447d","ebb202","094c83","e9a303","095489","e89705","095b8f","e68906","096494","ff8508","096c9a","ff7d07","0975a0","ff7506","097ca6","ff6b04","0984ac","ff6303","098cb2","ff5602","098cb2","ff6303","0984ac","ff6b04","097ca6","ff7506","0975a0","ff7d07","096c9a","ff8508","096494","e68906","095b8f","e89705","095489","e9a303","094c83","ebb202","09447d","ecbe00","093d77","f0c90c","093571","f4d318","092c6b","f7e214","092465","fbf10e","091e5f","faff08","09185a","d1f106","091354","ace405","090e4e","85d603","090948","60c902","0e0942","3bbb06"]},{colors:["c4d3f5","b9b4f8","af95fc","a476ff","f55757","f2768a","f096bd","edb5f0","18bc62","279d4d","367d37","455e22","887f4b","9a9434","adaa1d","bfbf06"]},{colors:["00f3ff","03efef","05e2dc","05d8cd","06ccbe","06bfad","05af9a","05a089","05937b","04876e","03755f","046351","064c3f","053a30","042821","000000","fff200","efdd06","e2cc03","ceb605","bfa404","ad9104","9e8004","8e7303","776105","665304","544504","443703","382e04","282102","191502","000000","ff5ae8","ef56e1","e256dc","d353d3","c14ec4","ac47b2","9c41a3","8a3d93","723b7a","5a3866","51325b","3c2542","2f1d33","251728","100a11","000000"]},{colors:["ff9d00","f29003","e28305","d37505","c66a05","b75e06","a35005","934606","843c06","723105","632b04","512303","3f1b02","331602","160901","000000","00ff42","03f43b","05e530","07d629","05c91c","06b712","04a808","049904","048904","047a04","056b05","045904","034703","033303","021902","000000","c35cff","b45bf4","a558e8","9857dd","8b54d1","7f53c4","724fb7","684dad","5b48a0","514493","464087","3c3b7a","323263","232344","141426","000000"]},{colors:["2e3dff","4143cc","534899","664e66","785333","8b5900","a25a33","b95b66","d15c98","e85dcb","ff5efe","f564f9","eb6bf4","e071f0","d678eb","cc7ee6","999ece","66bfb6","33df9e","00ff86","33df9e","66bfb6","999ece","cc7ee6","d678eb","e071f0","eb6bf4","f564f9","ff5efe","e85dcb","d15c98","b95b66","a25a33","8b5900","785333","664e66","534899","4143cc"]},{colors:["3bfffa","ffff00","3bfffa","00d88a","006b56","00d88a"]},{colors:["96ea03","ffff00","96ea03","00a804","0065c1","00a804","96ea03","ffff00","96ea03","00a804","0065c1","00a804","8ac110","dbd50e","8ac110","168916","09558e","168916","66891a","999504","66891a","1f5b1f","02375e","1f5b1f","66891a","999504","66891a","168916","09558e","168916","8ac110","dbd50e","8ac110","00a804","0065c1","00a804","96ea03","ffff00","96ea03","00a804","0065c1","00a804","96ea03","ffff00","96ea03"]},{colors:["00a804","0065c1","00a804","96ea03","ffff00","96ea03"]},{colors:["3bfffa","ffff00","3bfffa","00d88a","006b56","00d88a","3bfffa","ffff00","3bfffa","00d88a","006b56","00d88a","3bfffa","ffff00","3bfffa","00d88a","006b56","00d88a","ffff2e","50ff69","ffff2e","ffba1f","ff603b","ffba1f","ddd82c","47e25a","ddd82c","ce921b","e05338","ce921b","bfbb25","39bc48","bfbb25","aa7918","ad402a","aa7918","25afa8","a09c08","25afa8","049e63","01473a","049e63","2fd1c9","cec809","2fd1c9","04bc75","015646","04bc75","3bfffa","ffff2e","3bfffa","00d88a","006b56","00d88a","ffff2e","50ff69","ffff2e","ffba1f","ff603b","ffba1f","ffff2e","50ff69","ffff2e","ffba1f","ff603b","ffba1f","ffff00","50ff69","ffff2e","ffba1f","ff603b","ffba1f"]},{colors:["a6ffa4","ffc878","e0b8ff","ffff9f","048e00","b56700","7226bc","999500","a6ffa4","ffc878","e0b8ff","ffff9f","048e00","b56700","7226bc","999500"]},{colors:["f761ff","b80ac1","760c7c","000000","ff6c00","c16623","833700","000000","ffb500","c1972f","835d00","000000","deff5c","a8c145","78834d","000000","3efd51","00c013","00830d","000000","31eea8","00b673","007e4f","000000","355cf6","3f58bb","1b3080","000000","d8d8d8","aaaaaa","5e5e5e","000000","d8d8d8","aaaaaa","5e5e5e","000000","d8d8d8","aaaaaa","5e5e5e","000000","d8d8d8","aaaaaa","5e5e5e","000000","d8d8d8","aaaaaa","5e5e5e","000000","d8d8d8","aaaaaa","5e5e5e","000000"]},{colors:["fffb76","ffd6a1","ffb9ab","d69cff","a1a1ff","62d362","827b00","914c00","8e0000","710089","00139e","002600"]},{colors:["413248","31224c","221251","100055","0b0f5f","061f69","003073","003c68","00475e","005053","006142","00752f","5b7d08","8e7e00","9e8416","ad892c","bd8e44","bd7c4e","bd6a58","bd5862","b2517f","a64999","a446bd","8b43a0","733f82","593a65"]},{colors:["96ea03","ffff00","96ea03","00a804","0065c1","00a804","96ea03","ffff00","96ea03","00a804","0065c1","00a804","96ea03","ffff00","96ea03","00a804","0065c1","00a804","141414","e2e2e2","141414","cecece","141414","afafaf","141414","999999","141414","7f7f7f","141414","666666","141414","515151","141414","666666","141414","7f7f7f","141414","999999","141414","cecece","141414","ededed"]},{colors:["46004e","430077","764067","bb4444","ff6c41","d67534","ae752a","9a6e0f","97832e","69952c","079261","69952c","97832e","9a6e0f","ae752a","d67534","ff6c41","bb4444","764067","430077"]},{colors:["7af464","51d498","29b4cb","0094ff","0075e0","00508b","000000","00508b","0075e0","0094ff","29b4cb","51d498","7af464","51d498","29b4cb","0094ff","0075e0","00508b","000000","00508b","0075e0","0094ff","29b4cb","51d498"]},{colors:["f272fc","ae8ff9","78a7f9","5abcf9","67dbdb","69f4a2","ccff7b","fffdb3","ffe783","fcc665","f99d5f","f98a8a"]},{colors:["93f706","00db63","00bdc6","129aff","3976ff","8648ff","de00ea","ff2c2c","ff790b","ffae0b","ffdc0d","ffff08","9be732","27cb71","21aeb5","288eda","3f6dd3","6f41ca","bb14c3","da3c3c","e07b29","e6a92f","edd237","eeee35","a4d65e","4dbb7f","41a0a4","3f83b5","4563a8","593a95","97289d","b54c4c","c17e46","cda452","dac961","dede62","adc689","73aa8c","629193","557790","4a5a7c","423260","743c77","905b5b","a18064","b39f76","c8bf8b","cdcd8f","b5b5b5","9a9a9a","828282","6b6b6b","505050","2b2b2b","505050","6b6b6b","828282","9a9a9a","b5b5b5","bcbcbc","adc689","73aa8c","629193","557790","4a5a7c","423260","743c77","905b5b","a18064","b39f76","c8bf8b","cdcd8f","a4d65e","4dbb7f","41a0a4","3f83b5","4563a8","593a95","97289d","b54c4c","c17e46","cda452","dac961","dede62","9be732","27cb71","21aeb5","288eda","3f6dd3","6f41ca","bb14c3","da3c3c","e07b29","e6a92f","edd237","eeee35"]},{colors:["ffff08","bfbf06","808004","404002","000000","ffdc0d","cab015","95841c","605724","2b2b2b","ffae0b","d2951b","a67d2c","79653c","4c4c4c","ff790b","db7624","b6733c","927055","6d6d6d","ff2c2c","d23434","a63c3c","794444","4c4c4c","de00ea","b10bba","85168b","58205b","2b2b2b","8648ff","6536bf","432480","221240","000000","3976ff","3663ca","325195","2f3e60","2b2b2b","129aff","2186d2","2f73a6","3d6079","4c4c4c","00bdc6","1ba9b0","37959a","528183","6d6d6d","00db63","13b75d","269358","397052","4c4c4c","93f706","79c40f","5f9119","455e22","2b2b2b"]},{colors:["ffff08","bfbf06","808004","404002","000000","ffdc0d","d7bd22","b09e37","887f4b","606060","ffae0b","e2a52b","c59d4c","a8946c","8b8b8c","ff790b","ec8735","d9955e","c5a488","b2b2b2","ff2c2c","f55757","eb8181","e0abab","d6d6d6","de00ea","e33dec","e879ee","edb5f0","f2f2f2","8648ff","a476ff","c3a3ff","e1d1ff","ffffff","3976ff","6795fc","96b4f9","c4d3f5","f2f2f2","129aff","43a9f5","74b8eb","a5c7e0","d6d6d6","00bdc6","28b5bc","4faeb2","77a6a8","9e9e9e","00db63","18bc62","309e62","487f61","606060","93f706","79c40f","5f9119","455e22","2b2b2b"]},{colors:["6904aa","a366f2","4564ff","00b3dd","699319","91e205","a29f36","ffff2c","a84f25","ffa300","8e230a","ff4310"]},{colors:["e48100","f9491b","f91b7d","d600c8","a000c0","5600d5","0043f1","0079f4","008bf6","00aff8","3acddd","38e0cf","000000","3dea6a","000000","3dea6a","000000","3dea6a","000000","3dea6a","000000","3dea6a","000000","3dea6a","8df900","f9e800","f2c600","eba300"]},{colors:["f761ff","ff6c00","ffb500","cfff5c","31eea8","355cf6","eba1f1","e59c67","dab65d","b8d181","5fbf9d","586cba","dedede","c4c4c4","ababab","919191","787878","5e5e5e","eba1f1","e59c67","dab65d","b8d181","5fbf9d","586cba"]},{colors:["0038ad","4d64c1","9494d1","d0b5dd","ffb8e5","0038ad","3f5aca","767bdc","b3a5ee","d6b3ff","0038ad","306bc8","5a95da","80bceb","a1efff","0038ad","3772c1","69a7d2","92e7cd","c1ffb6","0038ad","457fb7","86d0a4","e7e2b7","ffe9b6","0038ad","4e76b7","9fc9ca","d8cebe","ffd3b3"]},{colors:["8d3400","a16a40","b59e80","c9c5a4","eaffb8","8d3400","aa6835","c69b6a","e3cc9e","fff0b3","8d3400","a85428","c37551","df9579","ffb1a1","8d3400","a1542e","b6735b","d9898c","ffb6f8","8d3400","975539","b37386","b1acd9","b6ccff","8d3400","975e40","a38480","a9b7c0","b3fff4"]},{colors:["deb3ff","c0a9bf","a3a080","859740","678d00","ffb6e5","d9acac","b3a273","8d9739","678d00","ffdeb6","d9ca89","b3b65b","8da12e","678d00","fffaa1","d9df79","b3c351","8da828","678d00","b3ffd3","a0e39e","8dc66a","7aaa35","678d00","b8ddff","a4c9bf","90b580","7ba140","678d00"]},{colors:["9f1ac1","9fffc1","c11b30","9fffc1","c14a08","9fffc1","c18308","9fffc1","c19f4c","9fffc1","bac14e","9fffc1","0fbe08","9fffc1","2e4fb4","9fffc1"]},{colors:["007732","226576","4453bb","6641ff","772bd6","8916ae","9a0085","972559","95492c","926e00","658e55","37adaa","0acdff","08b8cc","05a299","038d65"]},{colors:["fffb76","eae662","d5d04f","c1bb3b","aca627","979014","827b00","ffd6a1","edbf86","daa86b","c89151","b67a36","a3631b","914c00","ffb9ab","ec9a8e","d97b72","c75d56","b43e39","a11f1d","8e0000","d69cff","c582eb","b468d8","a34ec4","9334b0","821a9d","710089","a1a1ff","8689ef","6b72df","515acf","3642be","1b2bae","00139e","62d362","52b652","419941","317d31","216021","104310","002600"]},{colors:["5b1088","84106c","ad104f","d61033","ff1016","ff7398","ffadfe","fffe9d","e3d169","c7a434","ab7700","8b6d00","6a6300","4a5800","2a4e00","204a8a","446c68","688d45","8baf23","91e02f","72ef5f","54ff8e","69d2ff","698cff","6900ff","6946ff","4600aa","000000"]},{colors:["ccd4d2","a5bba5","87a79e","6b999f","56639d","60488d","562068","000000","5b3482","893b72","9d4f5f","b17652","cb9c44","cdb960","a9da46","b6e66e","c5f394","d2ffb9","ceefbf","cbe1c5","ccd4d2"]},{colors:["bbff15","fcfc03","ffcc29","ff8517","ff0000","b900d3","6f00ff","0000e0","003d03","0d1900","14a000","28ed18","fcfc03","28ed18","14a000","0d1900","14a000","28ed18","bbff15"]},{colors:["ba9393","d6a478","dddb8e","97c6a1","8898bf","927e9e"]},{colors:["9eb79e","8aa8a7","728c8b","577382","50537f","4d3568","401542","632b04","7f4040","9b6f48","bfa051","b1c97b","aaaaaa","828282","6b6b6b","4f4f4f","2d2d2d","000000","2d2d2d","4f4f4f","6b6b6b","828282","aaaaaa","cecece"]},{colors:["ff9d00","595959","494949","3d3d3d","303030","282828","111111","000000","00ff42","595959","494949","3d3d3d","303030","282828","111111","000000","c35cff","595959","494949","3d3d3d","303030","282828","111111","000000"]},{colors:["70e9f9","007c17","faff17","ff440b","5cff6f","f91cf4"]},{colors:["ffa6fd","3d9b53","f6ff80","ff2266","75a5fc","821afc"]},{colors:["a6ffa4","ffc878","e0b8ff","ffff9f","048e00","b56700","7226bc","999500","a6ffa4","ffc878","e0b8ff","ffff9f","048e00","b56700","7226bc","999500"]},{colors:["171717","363636","636363","7d7d7d","949494","b0b0b0","cccccc","e6e6e6","fff6ab","e3d169","c7a434","ab7700","e4100b","ff4574","fe7fe8","ffbffe","e6e6e6","cccccc","b0b0b0","949494","7d7d7d","636363","363636","171717","363636","636363","7d7d7d","949494","b0b0b0","cccccc","e6e6e6","a1a3ff","7d6de2","3c278b","0c1746","4e5300","68972f","45d05f","54ff86","e6e6e6","cccccc","b0b0b0","949494","7d7d7d","636363","363636"]},{colors:["ffff64","ea7103","ff83ff","1764e0","76ff89","ffc91f","20dbef","59037c","ff22b0","ffc610","016b06","ffcba4","ff0068","e8bbff","ff6b3e","ffff64","5bba00","ff83ff","ffc610","ff1a1a","20dbef","59037c","ff83ff","2626f9","ffe70b","0cbf10","374c82","374c82","eac5db","dbaf7f","9e9c5a","638463","434d7a","350074","d5d8c0","9ab79c","75999b","666b9e","513768","51001d","afcfdd","8faf80","93895c","8c6464","594263","1e194c","ffedd7","dccde8","91b5c9","899962","776b37","7c3200","e5dfea","d8b2d7","b2a360","6ca89d","486972","004e43","e1ffef","d4bfe8","8899b5","9e886f","4a5e43","472128","fffed4","d9ccea","9bc68b","a5889b","727246","23386d","b7e5a8","d8a7c2","ba9c78","5c8989","6b6143","422456","bccece","aaa97d","678c5d","896478","544734","292f4c"]},{colors:["002102","281dff","00aab2","47ff33","ffff55","ff5555","ffff55","47ff33","00aab2","281dff"]},{colors:["c5e3ff","8fe7ff","00e2ed","02c6a1","02a06f","067200","02a06f","02c6a1","00e2ed","8fe7ff","c5e3ff","e6eaff"]},{colors:["a0e0ad","7fbf94","69a482","53896f","376352","21443d","376352","53896f","69a482","7fbf94","a0e0ad","baf7c3"]},{colors:["000000","1c3312","2e531f","41752b","4e9830","66ba44","7add52","7fe755"]},{colors:["00ff18","17dd24","20bc24","2ea02e","367f36","2d5e2d","254425","1d301d","101910","000000","101910","1d301d","254425","2d5e2d","367f36","2ea02e","20bc24","17dd24"]},{colors:["0ff20f","00bc00","008e00","016801","004c00","002800","004c00","016801","008e00","00bc00","0ff20f","a4ffa4"]},{colors:["29f5ff","00c8dd","00a6b7","00878e","006070","003c4c","006070","00878e","00a6b7","00c8dd","29f5ff","8fffff"]},{colors:["9dad95","8b9981","738466","5e6d50","404c34","2b3322","404c34","5e6d50","738466","8b9981","9dad95","b6bfb2"]},{colors:["9dad95","8b9981","738466","5e6d50","404c34","2b3322","404c34","5e6d50","738466","8b9981","9dad95","b6bfb2","f4e4b0","edd383","e8c76b","dbb153","c99735","ba851c","c99735","dbb153","e8c76b","edd383","f4e4b0","f9edcf"]},{colors:["bab050","968e2d","7c771a","5e5c0d","444406","252605","444406","5e5c0d","7c771a","968e2d","bab050","d8cc77"]},{colors:["9e7d7d","896262","704343","563131","3f2222","0f0606","3f2222","563131","704343","896262","9e7d7d","bca2a2"]},{colors:["fffa43","efe800","dbd500","c6bc00","a59d00","898900","a59d00","c6bc00","dbd500","efe800","fffa43","fffaa4"]},{colors:["eb87b7","c47098","9d5a7a","76445c","4e2d3d","76445c","9d5a7a","c47098","9d5a7a","76445c","9d5a7a","c47098","91ad2d","aed036","91ad2d","748b24","57681b","3a4512","57681b","748b24","91ad2d","748b24","57681b","748b24","a8780e","d29611","fcb415","d29611","a8780e","7e5a0b","543c07","7e5a0b","a8780e","d29611","a8780e","7e5a0b","7c7735","a59f46","cfc657","f8ee69","cfc657","a59f46","7c7735","534f23","7c7735","a59f46","cfc657","a59f46","378493","2a636f","378493","45a5b8","53c6dd","45a5b8","378493","2a636f","1c424a","2a636f","378493","45a5b8"]},{colors:["2e2e59","6c40f4","c240ff","ff57ff","2e2e59","6c40f4","c240ff","ff57ff"]},{colors:["002d01","005e00","408200","79a500","b2c400","dde800","002d01","005e00","408200","79a500","b2c400","dde800","002d01","005e00","408200","79a500","b2c400","dde800","002d01","005e00","408200","79a500","b2c400","dde800"]},{colors:["277af4","3b78d1","4b74af","556b8c","4f5a6a","3d4147","232425","020202","277af4","3b78d1","4b74af","556b8c","4f5a6a","3d4147","232425","020202","277af4","3b78d1","4b74af","556b8c","4f5a6a","3d4147","232425","020202"]},{colors:["0e2d13","2a3921","564b2a","a98323","b8a949","c0c842","184c21","435435","756639","c89c2a","d7c655","dee74c","20642c","576c44","8d7b45","e0af2f","efdc5f","f5ff54","287d37","6c8554","a69151","e9b631","f4e061","f5ff54","329c45","86a468","c5ac60","f1bc33","f8e463","f5ff54","38af4e","96b774","d8bd69","efd220","fbe764","f5ff54","000000","3f3f3f","595959","7c7c7c","a5a5a5","c6c6c6","e5e5e5","f4f4f4","000000","303030","4c4c4c","727272","a5a5a5","d8d8d8","f4f4f4","000000","383838","606060","939393","cecece","f4f4f4","000000","3f3f3f","777777","c1c1c1","f4f4f4"]},{colors:["bcffb1","5f815a","020202","bcffb1","7eab77","40563c","020202","bcffb1","8ec085","5f815a","31412e","020202","bcffb1","97cc8e","729a6b","4c6748","273525","020202","bcffb1","9dd594","7eab77","5f815a","40563c","212c1f","020202","bcffb1","a1db98","87b77f","6c9366","526e4d","374a34","1d261b","020202","bcffb1","a5df9b","8ec085","76a06f","5f815a","486144","31412e","192218","020202"]},{colors:["2d145a","2d205a","2d2d5a","2d395a","2d465a","2d525a","2d5e5a","2d6b5a","2d775a","2d835a","2d905a","2d9c5a","2da95a","2db55a","3bbb57","4ac053","58c650","67cc4c","75d149","83d746","92dd42","a0e33f","aee83c","bdee38","cbf435","daf931","e8ff2e"]},{colors:["0572dd","fcbd83","fc4c62","a4f236","0061d6","ffb56c","ff3140","8ce815","0061d6","ffb56c","ff3140","8ce815","0457aa","d89456","db283d","7dc614","0457aa","d89456","db283d","7dc614","024c96","b57740","b22234","65a010","024c96","b57740","b22234","65a010","0457aa","d89456","db283d","7dc614","0457aa","d89456","db283d","7dc614","0061d6","ffb56c","ff3140","8ce815","0061d6","ffb56c","ff3140","8ce815","0572dd","fcbd83","fc4c62","a4f236"]},{colors:["efefef","e0b8ff","a6ffa4","d2d2d2","e0b8ff","a6ffa4","b2b2b2","e0b8ff","a6ffa4","959595","e0b8ff","a6ffa4","828282","e0b8ff","a6ffa4","959595","e0b8ff","a6ffa4","b2b2b2","e0b8ff","a6ffa4","d2d2d2","e0b8ff","a6ffa4"]},{colors:["002d01","005e00","408200","5e9e1b","60b70d","65d800","95ea00","cbed00","fff200","ffce00","ffa300","d88500","b26900","776b00","575e00","3b4900"]},{colors:["fff1ab","ffcb8d","ff952c","ff7900","ff952c","ffcb8d","f2ffde","c2ccff","557aff","00668e","00a6ef","7dcaff","d9ecff","6fff5f","15d800","148900","15d800","6fff5f","d5ff6e","eade00","a5a500","707000","a5a500","eade00"]},{colors:["4f0e0d","771514","9e1c1b","c52321","ed2a28","244344","366566","488687","5aa7a9","6cc9cb","51270b","793a11","a14d16","ca611b","f27421","483e48","6c5d6d","907c91","b49bb5","d8bad9","053518","085025","0a6b31","0c853d","0fa049","524e10","7b7619","a49d21","cdc429","f6eb31","171f38","222e55","2d3d71","2d3d71","394d8d","445ca9","4e2d3d","76445c","9d5a7a","c47098","eb87b7","3a4512","57681b","748b24","91ad2d","aed036","543c07","7e5a0b","a8780e","d29611","fcb415","4f0823","760c35","9d1047","c51458","ec186a","534f23","7c7735","a59f46","cfc657","f8ee69","1c424a","2a636f","378493","45a5b8","53c6dd"]},{colors:["31e7ff","2ccde3","26b4c6","219aaa","1b808e","166771","104d55","ff7712","e36a10","c65d0e","aa4f0c","8e420a","713508","552806","f9ff00","dde300","c2c600","a6aa00","8a8e00","6f7100","535500","373900","d80ae8","c009ce","a808b4","90079b","780681","600467","48034d","9cff33","8be32d","79c628","68aa22","578e1c","457117","345511","23390b","0f52e8","0d49ce","0c40b4","0a379b","082e81","072467","051b4d","ff877b","e3786d","c66960","aa5a52","8e4b44","713c37","552d29","391e1b","1ddd1d","1ac41a","17ac17","139313","107b10","0d620d","0a4a0a","063106","ff57eb","e34dd1","c644b7","aa3a9d","8e3083","712768","551d4e","391334","6a18ea","5e15d0","5213b6","47109c","3b0d82","2f0b68","23084e","180534"]},{colors:["000000","66320a","853b0b","a8460d","c94d10","e86112","ff8c5e","ffd3b5","000000","355707","25b84f","4ef581","6fff9b","9dffaf","c1ffd4","e4ffec","000000","4a4006","6e5d09","947b0c","bc9b0f","e3be20","ffdf56","fff3c1","000000","000040","3b1975","4c0fb6","6613f1","9456ff","b487ff","ccaeff","000000","193104","4a860b","82bc10","99dd19","acec70","daffb1","f3ffd3","000000","350000","5c072d","940c5a","c61077","e8129a","ff3fc4","ffa0ec","000000","0a417b","0e68b2","24b7ff","79ebff","a8f9ff","cffeff","edfffd"]},{colors:["009907","ff69b8","ffce00","009907","ff69b8","ffce00"]},{colors:["0061d6","ffb56c","ff3140","8ce815"]},{colors:["e7ff00","d3dd17","c1c129","aaa733","938e3d","7c783e","605c39","494632","333127","1c1b18","050505","1c1b18","333127","494632","605c39","7c783e","938e3d","aaa733","c1c129","d3dd17"]},{colors:["ff542c","50bcf9","ffff00","ff542c","50bcf9","ffff00","ed4726","4ab0dd","f4ed03","ed4726","4ab0dd","f4ed03","dd482a","47aad6","e8e205","dd482a","47aad6","e8e205","aa3721","3f8daf","bcb704","aa3721","3f8daf","bcb704","772717","2f6f8c","848003","772717","2f6f8c","848003","aa3721","3f8daf","bcb704","aa3721","3f8daf","bcb704","dd482a","47aad6","e8e205","dd482a","47aad6","e8e205","ed4726","4ab0dd","f4ed03","ed4726","4ab0dd","f4ed03","ff542c","50bcf9","ffff00","ff542c","50bcf9","ffff00","ff6648","62cbf9","fffc92","ff6648","62cbf9","fffc92"]},{colors:["b28e47","663e14","b28e47","94c979","4a7c47","94c979"]},{colors:["6b6b6b","595959","494949","3d3d3d","303030","282828","111111","000000","0aa511","ffff17","00897c","00d800","caff4a","22a028","000000","111111","282828","303030","3d3d3d","494949","595959","6b6b6b","7c7c7c"]},{colors:["026689","ff71f5","ff3600","026689","ff71f5","ff3600","03556b","e266df","e22c03","03556b","e266df","e22c03","035568","d860d5","e02f05","035568","d860d5","e02f05","024759","bc55ba","c62905","024759","bc55ba","c62905","023a49","8e428c","911e03","023a49","8e428c","911e03","024759","bc55ba","c62905","024759","bc55ba","c62905","035568","d860d5","e02f05","035568","d860d5","e02f05","03556b","e266df","e22c03","03556b","e266df","e22c03","026689","ff71f5","ff3600","026689","ff71f5","ff3600","067593","ff8dfc","fc5029","067593","ff8dfc","fc5029"]},{colors:["eca52b","d4a54a","c89c53","b59a63","90a09f","6da7b1","54a8db","43a9f5","54a8db","6da7b1","90a09f","b59a63","c89c53","d4a54a"]},{colors:["a03eff","3194ff","00d100"]}];
let leaves=[{pts:[{x:0,y:0},{x:0,y:0},{x:-30,y:-6},{x:-60,y:-30},{x:-48,y:-60},{x:-36,y:-52},{x:-12,y:-108},{x:12,y:-108},{x:36,y:-52},{x:48,y:-60},{x:60,y:-30},{x:30,y:-6}],hja:[{x:0,y:0},{x:0,y:0},{x:-30,y:6},{x:-90,y:-30},{x:-180,y:-210},{x:-36,y:-132},{x:-18,y:-228},{x:18,y:-228},{x:36,y:-132},{x:180,y:-210},{x:90,y:-30},{x:30,y:6}],bct:1.6,mct:-.1},{pts:[{x:0,y:0},{x:0,y:0},{x:-30,y:-24},{x:-42,y:-66},{x:-12,y:-96},{x:0,y:-108},{x:12,y:-96},{x:42,y:-66},{x:30,y:-24}],hja:[{x:0,y:0},{x:0,y:0},{x:-84,y:-30},{x:-114,y:-108},{x:-72,y:-162},{x:0,y:-204},{x:72,y:-162},{x:114,y:-108},{x:84,y:-30}],bct:0,mct:0},{pts:[{x:0,y:0},{x:0,y:0},{x:-60,y:-30},{x:-30,y:-30},{x:-60,y:-60},{x:-30,y:-60},{x:-48,y:-102},{x:-18,y:-84},{x:-12,y:-120},{x:0,y:-96},{x:12,y:-120},{x:18,y:-84},{x:48,y:-102},{x:30,y:-60},{x:60,y:-60},{x:30,y:-30},{x:60,y:-30}],hja:[{x:0,y:0},{x:0,y:0},{x:-120,y:-42},{x:-78,y:-48},{x:-102,y:-96},{x:-72,y:-90},{x:-84,y:-150},{x:-42,y:-138},{x:-30,y:-204},{x:0,y:-162},{x:30,y:-204},{x:42,y:-138},{x:84,y:-150},{x:72,y:-90},{x:102,y:-96},{x:78,y:-48},{x:120,y:-42}],bct:0,mct:.9},{pts:[{x:0,y:0},{x:0,y:0},{x:-24,y:-12},{x:-48,y:-42},{x:-42,y:-72},{x:-24,y:-90},{x:0,y:-48},{x:24,y:-90},{x:42,y:-72},{x:48,y:-42},{x:24,y:-12}],hja:[{x:0,y:0},{x:0,y:0},{x:-66,y:-12},{x:-102,y:-54},{x:-108,y:-132},{x:-48,y:-162},{x:0,y:-210},{x:48,y:-162},{x:108,y:-132},{x:102,y:-54},{x:66,y:-12}],bct:0,mct:.3},{pts:[{x:0,y:0},{x:0,y:0},{x:-24,y:-60},{x:-60,y:-72},{x:-42,y:-78},{x:-42,y:-108},{x:-12,y:-84},{x:0,y:-108},{x:12,y:-84},{x:42,y:-108},{x:42,y:-78},{x:60,y:-72},{x:24,y:-60}],hja:[{x:0,y:0},{x:0,y:0},{x:-42,y:-42},{x:-120,y:-84},{x:-66,y:-102},{x:-66,y:-180},{x:-42,y:-204},{x:0,y:-150},{x:42,y:-204},{x:66,y:-180},{x:66,y:-102},{x:120,y:-84},{x:42,y:-42}],bct:0,mct:-.3},{pts:[{x:0,y:0},{x:0,y:0},{x:-60,y:-12},{x:-18,y:-36},{x:-42,y:-102},{x:0,y:-90},{x:42,y:-102},{x:18,y:-36},{x:60,y:-12}],hja:[{x:0,y:0},{x:0,y:0},{x:-114,y:-18},{x:-108,y:-102},{x:-78,y:-186},{x:0,y:-156},{x:78,y:-186},{x:108,y:-102},{x:114,y:-18}],bct:0,mct:0},{pts:[{x:0,y:0},{x:0,y:0},{x:-48,y:-6},{x:-30,y:-30},{x:-60,y:-90},{x:-24,y:-72},{x:-42,y:-120},{x:-18,y:-102},{x:-6,y:-114},{x:0,y:-78},{x:6,y:-114},{x:18,y:-102},{x:42,y:-120},{x:24,y:-72},{x:60,y:-90},{x:30,y:-30},{x:48,y:-6}],hja:[{x:0,y:0},{x:0,y:0},{x:-120,y:-12},{x:-96,y:-60},{x:-120,y:-180},{x:-96,y:-180},{x:-90,y:-240},{x:-30,y:-180},{x:-18,y:-228},{x:0,y:-174},{x:18,y:-228},{x:30,y:-180},{x:90,y:-240},{x:96,y:-180},{x:120,y:-180},{x:96,y:-60},{x:120,y:-12}],bct:0,mct:.8},{pts:[{x:0,y:0},{x:0,y:0},{x:-60,y:-90},{x:-30,y:-66},{x:-42,y:-108},{x:-18,y:-78},{x:-18,y:-120},{x:0,y:-54},{x:18,y:-120},{x:18,y:-78},{x:42,y:-108},{x:30,y:-66},{x:60,y:-90}],hja:[{x:0,y:0},{x:0,y:0},{x:-120,y:-150},{x:-78,y:-150},{x:-78,y:-234},{x:-42,y:-186},{x:-18,y:-240},{x:0,y:-210},{x:18,y:-240},{x:42,y:-186},{x:78,y:-234},{x:78,y:-150},{x:120,y:-150}],bct:0,mct:.9},{pts:[{x:0,y:0},{x:0,y:0},{x:-60,y:-18},{x:-36,y:-24},{x:-60,y:-60},{x:-30,y:-48},{x:-36,y:-96},{x:-12,y:-60},{x:0,y:-36},{x:12,y:-60},{x:36,y:-96},{x:30,y:-48},{x:60,y:-60},{x:36,y:-24},{x:60,y:-18}],hja:[{x:0,y:0},{x:0,y:0},{x:-120,y:-18},{x:-96,y:-54},{x:-108,y:-108},{x:-72,y:-114},{x:-60,y:-180},{x:-12,y:-102},{x:0,y:-114},{x:12,y:-102},{x:60,y:-180},{x:72,y:-114},{x:108,y:-108},{x:96,y:-54},{x:120,y:-18}],bct:0,mct:.2},{pts:[{x:0,y:0},{x:0,y:0},{x:-60,y:-120},{x:-30,y:-90},{x:-30,y:-108},{x:-18,y:-84},{x:-12,y:-102},{x:-6,y:-72},{x:0,y:-90},{x:6,y:-72},{x:12,y:-102},{x:18,y:-84},{x:30,y:-108},{x:30,y:-90},{x:60,y:-120}],hja:[{x:0,y:0},{x:0,y:0},{x:-120,y:-180},{x:-96,y:-216},{x:-66,y:-198},{x:-48,y:-222},{x:-30,y:-204},{x:-12,y:-222},{x:0,y:-180},{x:12,y:-222},{x:30,y:-204},{x:48,y:-222},{x:66,y:-198},{x:96,y:-216},{x:120,y:-180}],bct:.8,mct:.3},{pts:[{x:0,y:0},{x:0,y:0},{x:-48,y:-30},{x:-54,y:-54},{x:-48,y:-84},{x:-24,y:-114},{x:0,y:-120},{x:24,y:-114},{x:48,y:-84},{x:54,y:-54},{x:48,y:-30},{x:0,y:0}],hja:[{x:0,y:0},{x:0,y:0},{x:-96,y:-48},{x:-120,y:-132},{x:-90,y:-192},{x:-30,y:-234},{x:0,y:-240},{x:30,y:-234},{x:90,y:-192},{x:120,y:-132},{x:96,y:-48}],bct:0,mct:0},{pts:[{x:0,y:0},{x:0,y:0},{x:-30,y:-24},{x:-42,y:-60},{x:-18,y:-96},{x:0,y:-120},{x:18,y:-96},{x:42,y:-60},{x:30,y:-24}],hja:[{x:0,y:0},{x:0,y:0},{x:-78,y:-42},{x:-84,y:-132},{x:-42,y:-186},{x:0,y:-240},{x:42,y:-186},{x:84,y:-132},{x:78,y:-42}],bct:0,mct:.3},{pts:[{x:0,y:0},{x:0,y:0},{x:-30,y:-12},{x:-48,y:-30},{x:-54,y:-54},{x:-48,y:-72},{x:-30,y:-90},{x:-12,y:-102},{x:0,y:-108},{x:12,y:-102},{x:30,y:-90},{x:48,y:-72},{x:54,y:-54},{x:48,y:-30},{x:30,y:-12}],hja:[{x:0,y:0},{x:0,y:0},{x:-60,y:-6},{x:-96,y:-30},{x:-102,y:-66},{x:-84,y:-108},{x:-54,y:-144},{x:-24,y:-162},{x:0,y:-168},{x:24,y:-162},{x:54,y:-144},{x:84,y:-108},{x:102,y:-66},{x:96,y:-30},{x:60,y:-6}],bct:0,mct:0}];
The Fractal Bloom generative collection draws inspiration from sacred geometry, plant growth, and the shimmering brilliance of akoya pearls. Each shape unfurls into logarithmic spirals, mimicking blooming flowers, fractals, and patterns of the universe. Born from an infinite cycle, these colorful petals grow into bejeweled blooms vibrating with ethereal energy. Artwork and concept created by Jen Stark. Coding by Jorge Ledezma.
The Fractal Bloom collection draws inspiration from sacred geometry, plant growth, and the shimmering brilliance of akoya pearls. Each shape unfurls into logarithmic spirals, mimicking blooming flowers, fractals, and patterns of the universe. Born from an infinite cycle, these colorful petals grow into bejeweled blooms vibrating with ethereal energy. Artwork and concept created by Jen Stark. Coding by Jorge Ledezma.