Skip to content

Instantly share code, notes, and snippets.

@echophon
Created August 6, 2014 05:40
Show Gist options
  • Save echophon/f6503c359bb6c3e3d298 to your computer and use it in GitHub Desktop.
Save echophon/f6503c359bb6c3e3d298 to your computer and use it in GitHub Desktop.
/*
* Alt Wave
* by Yancy Way (Echophon) - twitter.com/echophons - echophon.tumblr.com
*/
//requires HYPE.pde (staging)
//requires HOrbiter
void setup() {
size(500, 500);
H.init(this).background(#BBBBFF).autoClear(true);
smooth();
HColorPool c = new HColorPool(#202020);
for (int i=1; i<=82; i++){
for (int j=1; j<=82; j++){
HRect r = new HRect(3);
r.rounding(10).anchorAt(H.CENTER).noStroke().fill(c.getColor());
H.add(r);
HOrbiter o = new HOrbiter()
.target(r)
.speed(-1)
.radius(25)
.startAngle(j*15+i)
.parent(
new HOrbiter().speed(1).startAngle(-i*15+j).radius(21).parent(
new HOrbiter().speed(-1).startAngle(-j*15+j).radius(17).parent(
new HOrbiter(j*12-100, i*12-100).speed(1).startAngle(i*15-j).radius(14)
)
)
)
;
}
}
}
void draw() {
H.drawStage();
if ( frameCount % 2 ==0 && frameCount <= 360){
saveFrame("image-####.gif");
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment