The following pieces are sketches I produced when tinkering with Processing. This was the first time that I tried generating art. I would not consider these sketches as art yet, but as a preliminary stage of such.

I loved playing around with the numbers and variables. When I have a bit more time again after finishing my final major project I’m currently working on I definitely come back to that.

 

Hint: You can find the code of the last stage at the bottom.

Starting point

Adding rotation

Last draft

 

CODE


float x;
float y;

void setup()
{
  size(1024,768);
  background(0);
  smooth();

  noStroke();
  fill(255,200);
}

void draw()
{
  for(x=0; x < width; x += 4)
  {
    y = height/2 + sin(x/40) * height/8;
    ellipse(x, y, 1, 1);
    noFill();
    stroke(255,20);
    strokeWeight(0.25);
    ellipse(x, y, y/4, y/4);

    stroke(255,10);
    rotate(sin(mouseY)+sin(mouseX));

    noStroke();
    fill(255,10);
    ellipse(x, y-height/4, y, y);

    fill(0,20);
    ellipse(x+width/4, y+height/4, y/8, y/8);
  }
}

void mousePressed()
{
  save("image_"+millis()+".jpg");
  background(0,127);
}