Advertisement
xeromino

virus

Apr 1st, 2014
131
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.55 KB | None | 0 0
  1. float h, w, theta;
  2. int num = 100;
  3.  
  4. void setup() {
  5.   size(500, 500);
  6.   ellipseMode(CORNER);
  7.   noStroke();
  8.   fill(#6A0202,50);
  9.   background(255);
  10.   //frameRate(10);
  11. }
  12.  
  13. void draw() {
  14.   w = 20;
  15.   h = map(sin(theta), -1, 1, w, 200);
  16.   translate(width/2, height/2);
  17.   for (int i=0; i<num; i++) {
  18.     pushMatrix();
  19.     rotate((TWO_PI/num)*i);
  20.     ellipse(-w/2, 0, w, h);
  21.     popMatrix();
  22.   }
  23.   filter(DILATE);
  24.   //filter(BLUR,.6);
  25.   theta += 0.0523;
  26.   //noLoop();
  27.  
  28.   if (frameCount%4==0 && frameCount<121) saveFrame("image-###.gif");
  29.  
  30. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement