+ for (LXVector p: sinespin)
+ // for (Point p: model.points)
+ {
+ P.set(p.x, p.y, p.z);
+ // PVector P = new PVector(p.x, p.y, p.z);
+ color c = #000000;
+ c = blendIfColor(c, spherys[1].spheryvalue(P), ADD);
+ c = blendIfColor(c, spherys[0].spheryvalue(P), ADD);
+ c = blendIfColor(c, spherys[2].spheryvalue(P),ADD);
+
+
+ colors[p.index] = c;
+
+
+ }
+ sinespin2.reset()
+ .center()
+ .rotate(yrot2.getValuef(), rotationx.getValuef(), rotationy.getValuef() , rotationz.getValuef())
+ .translate(model.cx,model.cy,model.cz);
+
+ for (LXVector p: sinespin2)
+ { color c = 0;
+ // PVector P = new PVector(p.x, p.y, p.z);
+ P.set(p.x, p.y, p.z);
+ c = blendIfColor(c, spherys[3].spheryvalue(P),ADD);
+
+ colors[p.index] = blendIfColor(colors[p.index], c , ADD);
+
+ }
+ sinespin3.reset()
+ .center()
+ .rotate(yrot3.getValuef(), -1 + rotationx.getValuef(), rotationy.getValuef(), rotationz.getValuef())
+ .translate(model.cx, model.cy, model.cz);
+ for (LXVector p: sinespin3)
+ { color c = 0;
+ // PVector P = new PVector(p.x, p.y, p.z);
+ P.set(p.x, p.y, p.z);
+ c = blendIfColor(c, spherys[4].spheryvalue(P),ADD);
+
+ colors[p.index] = blendIfColor(colors[p.index], c , ADD);
+
+ }
+
+
+
+ }
+
+ color blendIfColor(color c1, color c2, int mode) {
+ if (c2 != 0) {
+ return blendColor(c1, c2, mode);
+ }
+ return c1;