YouieCho-Project-01-Face

sketch

//Youie Cho minyounc Section E
function setup() {
    createCanvas(600, 600);
    background(255, 149, 0);
    //hair
    fill(0);
    bezier(120, 250, 116, 150, 150, 100, 218, 90);
    bezier(218, 90, 250, 20, 465, 30, 480, 250);
    rect(120, 250, 360, 300);
    triangle(120, 250, 218, 90, 480, 250);
    //neck
    noStroke();
    fill(245, 214, 179);
    rect(220, 300, 160, 300);
    //ears
    ellipse(170, 275, 40, 80);
    ellipse(430, 275, 40, 80);
    //face
    fill(255, 231, 204);
    bezier(165, 220, 170, 500, 430, 500, 435, 220);
    bezier(165, 220, 180, 35, 400, 120, 435, 220);
    //nose
    fill(245, 214, 179);
    quad(290, 230, 310, 230, 330, 300, 275, 300);
    bezier(275, 300, 290, 315, 315, 315, 330, 300);
    //under eyes and white
    fill(255);
    bezier(205, 240, 218, 250, 250, 250, 260, 240);
    bezier(340, 240, 350, 250, 382, 250, 395, 240);
    stroke(0);
    strokeWeight(2);
    fill(255);
    bezier(202, 240, 218, 220, 250, 220, 260, 240);
    bezier(340, 240, 350, 220, 382, 220, 397, 240);
    //pupils
    fill(20, 27, 8);
    noStroke();
    ellipse(235, 235, 23, 22);
    ellipse(365, 235, 23, 22);
    //eyes
    stroke(0);
    strokeWeight(2);
    noFill();
    bezier(202, 240, 218, 220, 250, 220, 260, 240);
    bezier(340, 240, 350, 220, 382, 220, 397, 240);
    //eyebrows
    noStroke();
    fill(71, 39, 32);
    quad(204, 205, 265, 205, 265, 211, 195, 211);
    quad(334, 205, 393, 205, 402, 211, 334, 211);
    //eyelids
    noFill();
    stroke(100);
    strokeWeight(1);
    bezier(200, 236, 218, 217, 250, 217, 261, 237);
    bezier(338, 238, 350, 217, 382, 217, 400, 236);
    //mouth
    noStroke();
    fill(186, 64, 50);
    bezier(250, 340, 270, 375, 330, 375, 350, 340);
    //clothes
    fill(108, 227, 102);
    arc(300, 530, 250, 250, -QUARTER_PI, PI + QUARTER_PI);
    fill(88, 180, 81);
    rect(50, 550, 500, 50);
    quad(50, 550, 180, 500, 420, 500, 550, 550);
}

It was very fun to be able to draw with code for the first time. There were some trials and errors, but I could eventually figure it out with the reference.

Leave a Reply