memoscan
← all memos

Memo 0x59ac83fc…bcaccc on Ethereum

[e][s].x,rg.gPts[c][e][s].y,rg.gPts[c][e][s].z);pop()}function windowResized(){DIM=min(windowWidth,windowHeight),resizeCanvas(DIM,DIM)}function setLineDash(e){drawingContext.setLineDash(e)}function dash_line(e,t,r,o,a,s,c,n){let i=createVector(e,t,r),l=createVector(o,a,s),m=p5.Vector.sub(l,i),h=m.mag(),d=int(h/(c+n));push(),translate(e,t,r);let g=m.copy().setMag(c),f=m.copy().setMag(c+n);for(let e=0;e<d;e++)line(0,0,0,g.x,g.y,g.z),translate(f.x,f.y,f.z);pop()}function updateCam(){for(push(),rotateZ(cam[2]),rotateY(cam[1]),push(),i=0;i<steps;i++)0==renderPattern[i]?(texture(myImg),model(goModels[i])):1==renderPattern[i]||(2==renderPattern[i]?(noStroke(),fill(255),model(goModels[i]),noFill()):3==renderPattern[i]?(stroke(0),strokeWeight(1),noFill(),model(goModels[i]),noStroke()):4==renderPattern[i]?(stroke(0),strokeWeight(1),fill(255),model(goModels[i]),noStroke(),noFill()):5==renderPattern[i]?(texture(myImg),stroke(0),strokeWeight(1),model(goModels[i]),noStroke()):(noStroke(),texture(myImg),model(goModels[i])));if(pop(),1==BKGRID&&drawGrid(),pop(),ratio>0&&ratio<1){ratio>=.99999&&(ratio=1),zoom=lerp(zoomStart,zoomTarg,ratio),cam[0]=lerp(camStart[0],camTarg[0],ratio),cam[1]=lerp(camStart[1],camTarg[1],ratio),cam[2]=lerp(camStart[2],camTarg[2],ratio),v=lerp(vStart,vTarg,ratio);let e=1-ratio;ratio+=e*easing,1==camZoomInit&&(ratio=.99999,zoom=defaultZoom/2,camZoomInit=!1)}ortho(-v*zoom,v*zoom,-v*zoom,v*zoom,-1e4,1e4)}function pointRotateY(e,t){let r=new p5.Vector;return r.x=e.z*Math.sin(t)+e.x*Math.cos(t),r.y=e.y,r.z=e.z*Math.cos(t)-e.x*Math.sin(t),r}function pointRotateZ(e,t){let r=new p5.Vector;return r.x=e.x*Math.cos(t)-e.y*Math.sin(t),r.y=e.x*Math.sin(t)+e.y*Math.cos(t),r.z=e.z,r}function reflect3d(e,t){let r=new p5.Vector(0,0,0),o=new Face(t.facePts[0],t.facePts[1],t.facePts[2]),a=new p5.Vector(o.facePts[0].x,o.facePts[0].y,o.facePts[0].z),s=p5.Vector.sub(o.facePts[1],o.facePts[0]),c=p5.Vector.sub(o.facePts[2],o.facePts[0]),n=c.cross(s);if(n.normalize(),gTestPV0=a,gTestPV1=s,gTestPV2=c,0==e.dist(o.facePts[0])||0==e.dist(o.facePts[1])||0==e.dist(o.facePts[2]))r.x=e.x,r.y=e.y,r.z=e.z;else{let t=p5.Vector.sub(e,o.facePts[0]),s=Math.abs(t.angleBetween(n)),c=t.cross(n);c.normalize(),c.mult(20),testCross1=new p5.Vector(c.x,c.y,c.z),c.normalize();let i=n.cross(c);i.normalize(),i.mult(t.mag()*sin(s)),n.normalize(),n.mult(t.mag()*cos(s));let l=new p5.Vector(n.x,n.y,n.z);l.mult(-1),r.x=l.x,r.y=l.y,r.z=l.z,retV1=new p5.Vector(r.x,r.y,r.z),r.add(i),retV2=new p5.Vector(r.x,r.y,r.z),r.add(a),retV3=new p5.Vector(r.x,r.y,r.z)}return r}function scale3d(e,t,r){let o=new p5.Vector(0,0,0);return o.x=e.x+-1*t.x,o.y=e.y+-1*t.y,o.z=e.z+-1*t.z,o.x=o.x*r,o.y=o.y*r,o.z=o.z*r,o.x=o.x+t.x,o.y=o.y+t.y,o.z=o.z+t.z,o}function vertex_average(e){let t=new p5.Vector(0,0,0);for(let r=0;r<e.length;r++)t.x=t.x+e[r].x,t.y=t.y+e[r].y,t.z=t.z+e[r].z;let r=e.length;return t.x=t.x/r,t.y=t.y/r,t.z=t.z/r,t}document.oncontextmenu=(()=>!1);class Random{constructor(){this.useA=!1;let e=function(e){let t=parseInt(e.substr(0,8),16),r=parseInt(e.substr(8,8),16),o=parseInt(e.substr(16,8),16),a=parseInt(e.substr(24,8),16);return function(){t|=0,r|=0,o|=0,a|=0;let e=(t+r|0)+a|0;return a=a+1|0,t=r^r>>>9,r=o+(o<<3)|0,o=o<<21|o>>>11,o=o+e|0,(e>>>0)/4294967296}};this.prngA=new e(tokenData.hash.substr(2,32)),this.prngB=new e(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(e,t){return e+(t-e)*this.random_dec()}random_int(e,t){return Math.floor(this.random_num(e,t+1))}}let R,R1,R2,R3,R4,R10,R11,grw;R=new Random,R1=new Random,R2=new Random,R3=new Random,R4=new Random,R10=new Random,R11=new Random;class Category{constructor(e=[{name:"default",chance:1,amount:1,min:0,max:1}]){this.count=500,this.arr=e,this.select={}}setByAmount(){let e=0;for(let t=0;t<this.arr.length;t++)e+=this.arr[t].amount;this.count=e;for(let e=0;e<this.arr.length;e++)this.arr[e].chance=this.arr[e].amount/this.count}setByChance(e=this.count){let t=0;for(let e=0;e<this.arr.length;e++)t+=this.arr[e].chance;if(t>=.9999999999&&t<=1.00000000001)for(let e=0;e<this.arr.length;e++)this.arr[e].amount=this.arr[e].chance*this.count;else console.log("Improper Sum: "+t)}sum(){let e=[],t=[];t.push(0);for(let r=0;r<this.arr.length;r++)e.push(this.arr[r].chance),t.push(this.arr[r].chance);t.pop(),e=partialSum(e),t=partialSum(t);for(let r=0;r<this.arr.length;r++)this.arr[r].min=t[r],this.arr[r].max=e[r]}pickCategory(){let e,t=R.random_dec();for(let r=0;r<this.arr.length;r++)this.arr[r].min<=t&&t<this.arr[r].max&&(e=this.arr[r].name);return this.select={name:e,value:t},{name:e,value:t}}setCategory(e){let t,r=0;for(let r=0;r<this.arr.length;r++)e==this.arr[r].name&&(t=this.arr[r].name);return this.select={name:t,value:r},{name:t,value:r}}setCategoryValue(e){let t,r;for(let o=0;o<this.arr.length;o++)this.arr[o].min<=e&&e<this.arr[o].max&&(r=this.arr[o].name,t=e);return this.select={name:r,value:t},{name:r,value:t}}}let currGo,currFace,currPoint,targetPt,go=[],resetGo=[],goDepot=[],resetDepot=[],steps=0,currArraySize=0,zflag=0,sun=new p5.Vector(1,-1,1);sun.normalize();let geom,timer,img,centerX,centerY,centerZ,xMin,xMax,yMin,yMax,zMin,zMax,goNum,rand,rand1,rand2,rand3,zoomRR,num,myAngle=0,mGo=0,goModels=[],goModelsDepot=[],delay=3,bBox=[],currCluster=0,grow=1,initGrow=!0;var DEFAULT_SIZE=1400,WIDTH=window.innerWidth,HEIGHT=window.innerHeight,DIM=Math.min(WIDTH,HEIGHT),M=DIM/DEFAULT_SIZE;let myImg,canvas,shaderA,rg,patternSelect,bkImg,shaderBK,bkUniform,Lstring="ffff+fff",shad_Size=512,drawTex=!0,UNI=["LF1","LF2","LR1","LR2","dA1","dA2","df1","df2","wb1","wb2","bb1","bb2","Nf1","Nf2","Nn1","Nn2","Nx1","Nx2","indx","Ld","cBlend"],sG=10,UNIVAR=[[[54.64+sG,49.324+sG,40.324+sG,50+sG],[80.48+sG,0],[1.57079632679,-.788,-.788,-4.668],[3.604,0],[2,100.16,100.16,2.88],[2.88,0],[147.2,516.8,516.8,589.6],[589.6,0],[3.424,4.816,4.816,4.056],[3.592,0],[1.484,.86,.86,.86],[.86,0],[40,43.752,41.752,24.216],[0,1.2],[-.02,-.26,-.26,.1],[0,0],[.304,.376,.376,.376],[0,1],1,[0,0,0,0],.796],[[52.696+sG,54.324+sG,55.324+sG,62.392+sG],[80.48+sG,0],[0,.796,1.64,3.196],[5.332,5],[11.712,100.16,100.16,2.88],[2.88,0],[247.2,516.8,516.8,589.6],[589.6,0],[2.904,3.608,3.192,3.224],[3.592,0],[1.484,.86,.86,.86],[.86,0],[16.376,35.832,36.136,3.312],[4.152,-1.152],[0,.22,-.124,.1],[.1,.1],[0,.4,.56,1.128],[1.128,1],2,[0,0,0,0],.796],[[54.64+sG,49.324+sG,49.324+sG,49.284+sG],[80.48+sG,0],[0,1.58,4.548,2.316],[3.604,0],[11.712,100.16,100.16,98.696],[2.88,0],[247.2,516.8,516.8,621.6],[589.6,0],[3.488,3.088,3.056,3.848],[3.592,0],[1.484,.86,.86,.86],[.86,0],[16.376,35.832,36.136,36.136],[4.152,-1.5],[-0,-.26,-.124,-.124],[.1,.1],[.4,.4,.56,.592],[1.128,1],3,[0,0,0,0],.796],[[60.32+sG,49.324+sG,49.324+sG,49.284+sG],[80.408+sG,0],[2.227,.836,6.828,2.316],[3.932,0],[11.632,11.256,100.16,98.696],[2.88,0],[553.6,290.4,516.8,621.6],[589.6,0],[2.92,3.84,3.712,3.88],[2.832,0],[.276,1.188,.86,.86],[.86,0],[16.376,35.832,36.136,36.136],[4.152,.7],[.388,.212,-.124,-.124],[.1,.1],[1.024,.424,.56,.592],[1.544,1],4,[-.168,2.336,1.506,.952],.81],[[53.72+sG,46.468+sG,49.324+sG,49.284+sG],[50.352+sG,0],[3.963,2.032,6.876,.1],[2.604,0],[13.384,11.112,100.16,98.696],[3.24,0],[487.2,290.4,516.8,621.6],[589.6,0],[2.696,2.808,2.488,2.96],[1.464,0],[.196,1.188,.9,.86],[.86,0],[16.376,35.832,24.264,33.872],[3.2,-.8],[.572,.212,-.124,-.124],[-.084,.05],[.976,.656,.48,.592],[1.816,.9],5,[.63,.378,.601,3.632],.924],[[58.408+sG,46.468+sG,53.916+sG,51.336+sG],[40.424+sG,0],[4.707,1.104,6.676,2.596],[2.98,0],[12.208,10.12,100.16,98.704],[2.88,0],[578.4,290.4,516.8,621.6],[589.6,0],[1.156,2.376,2.376,2.168],[2.208,0],[.708,1.188,.86,.86],[.86,0],[18.168,40.832,25,3.136],[3.112,1.112],[.108,.212,-.124,-.116],[.1,.1],[1.304,.512,.56,1.072],[1.104,1.104],6,[0,0,0,0],.796],[[60.32+sG,60.324+sG,61.692+sG,61.336+sG],[50.424+sG,0],[2.091,.796,4.724,2.596],[4.788,0],[18.376,10.544,100.16,98.704],[2.88,0],[553.6,444,516.8,621.6],[589.6,0],[1.616,2.28,2.72,2.312],[1.776,0],[1.484,1.188,.86,.86],[.86,0],[16.744,35.832,36.136,3.136],[4.336,0],[.388,.212,-.508,-.124],[.1,0],[1.096,1.248,1.36,.592],[1.768,0],7,[0,0,0,0],.796],[[60.32+sG,80.324+sG,51.692+sG,60.368+sG],[1+sG,0],[6.427,1.012,6.828,4.836],[1,0],[11.632,10.056,100.16,98.696],[4,0],[553.6,444,516.8,621.6],[.4,0],[1.44,.92,2.256,2.024],[.2,0],[1.484,1.188,.86,.86],[.2,0],[16.16,35.832,36.136,3.136],[.1,0],[.388,.212,-.508,-.124],[0,0],[1.096,1.248,1.784,.496],[0,0],8,[0,0,0,0],.796]],gBorder=1,gScale=20,gVals=7+gBorder,growth_Max=7,growth_percent=.5,growth_type_ratio=.5,small_death_chance=.1,BKGRID=!1,bkGridTrueMax=27,bkGridDrawBoundsX=11,bkGridDrawBoundsY=11,bkGridDrawBoundsZ=11,pS=1,BKTEXT=!1,bkrez=2048,bkSCALE=250,bkrot=0,bkfreq=0,bkamp=0,bkNscale=0,bkNmin=0,bkNmax=0,pattDirector=[],pattOrgClust=[[0,0,-1],[1,2,0],[2,2,0],[4,2,0],[5,2,0],[7,2,0],[3,2,1],[4,3,1],[6,2,1],[7,2,1]],pattOrgBranch=[[1,3,3],[2,4,3],[1,4,3],[1,3,3],[2,4,3],[1,4,3],[1,5,1],[1,6,1],[1,7,1],[2,5,1],[3,4,1]],pattOrgLoop=[[4,4,1],[4,5,1],[5,4,1],[5,5,1],[6,5,1],[7,3,1],[7,4,1]],pattOrgLine=[[8,3,3],[8,4,3],[8,3,3],[8,4,3],[8,3,3],[8,4,3],[8,5,1],[8,6,1],[8,7,1]],pattOrgHole=[[10,0,-1],[10,0,-1],[10,0,-1],[2,3,1],[4,4,1],[6,3,1]],pattOrgPT=[[9,0,-1],[9,0,-1],[9,0,-1],[9,0,-1],[9,0,-1],[9,0,-1],[9,0,0],[9,0,0],[9,0,0],[9,0,0],[9,0,0],[9,0,0],[9,0,1]],ERASE=!1,WIREFRAME=!1,OPAQUE=!1,scale_lib=[{name:"fit",chance:.8},{name:"zoom",chance:.2}],colr_lib=[{name:"warm",chance:.55},{name:"cool",chance:.15},{name:"grey",chance:.2},{name:"white",chance:.1}],bkgd_lib=[{name:"blank",chance:.3},{name:"grid lattice",chance:.15},{name:"linear hatch",chance:.07},{name:"noise hatch",chance:.08},{name:"cross hatch",chance:.1},{name:"stipple hatch",chance:.1},{name:"dark hatch",chance:.2}],patt_lib=[{name:"cluster",chance:.55},{name:"branch",chance:.1},{name:"loop",chance:.05},{name:"hole",chance:.1},{name:"line",chance:.1},{name:"point",chance:.1}],frac_lib=[{name:"minimal"