mdambruc-Project-01-Face

mdambruc-Portrait

//Mairead Dambruch
//Section C
//mdambruc@andrew.cmu.edu
//Project-01

function setup() {
    createCanvas(600, 600);
    background(108, 182, 185);

}

function draw() {
  fill(185, 142, 149);
  noStroke();
  rect(162, 400, 250, 250);//shirt

  fill(243, 232, 185);
  noStroke();
  ellipse(165, 500, 55, 200); //left arm

  fill(243, 232, 185);
  noStroke();
  ellipse(415, 500, 55, 200); //right arm

  fill(129, 68, 41);
  noStroke();
  rect(180, 205, 240, 200);//hair

  fill(243, 232, 185);
  noStroke();
  rect(263, 355, 60, 60);//neck

  fill(243, 232, 185);
  noStroke();
  ellipse(293, 270, 200, 200);//face

  fill(129, 68, 41);
  noStroke();
  arc(300, 250, 255, 255, PI, TWO_PI, OPEN);//bangs

  strokeWeight(2);
  stroke(0);
  fill(255);
  ellipse(342, 270, 25, 20); //right eye

  strokeWeight(1);
  fill(162, 142, 23);
  ellipse(342, 270, 15, 17);
  strokeWeight(10);
  point(342, 270);// right eye iris pupil

  strokeWeight(2);
  stroke(0);
  fill(255);
  ellipse(250, 270, 25, 20); //left eye
  strokeWeight(1);
  fill(162, 142, 23);
  ellipse(250, 270, 15, 17);
  strokeWeight(10);
  point(250, 270);// left eye iris pupil
  if (mouseX < (width / 2)) {
    strokeWeight(2);
    stroke(0);
    arc(250, 270, 25, 20, TWO_PI, PI);//eye twitch
  }


  fill(164, 32, 82);
  noStroke();
  arc(295, 305, 70, 70, TWO_PI, PI, OPEN);//mouth

  fill(185, 142, 149);
  triangle(293, 306, 300, 306, 297, 320);//uvula

  fill(185, 142, 149);
  ellipse( 297, 320, 7, 7);






}

This project also involved a lot of trial and error for me but was overall a good way to learn about the text editor. The project resulted in a happy accident that led to an eye twitch instead of a wink, which is probably more accurate for my self portrait.

2 thoughts on “mdambruc-Project-01-Face”

Leave a Reply