Project 1 – Self Portrait

Here’s my self portrait

sketch
function setup() {
    createCanvas(700, 900);
    background(151, 210, 165);
    text("p5.js vers 0.9.0 test.", 10, 15);
}

function draw() {
    fill(54, 36, 28); //hair
    noStroke();
    ellipse(350, 400, 600);
    square(50, 400, 600);
    fill(203, 175, 125); //neck+ears
    rect(200, 450, 300, 700);
    quad(75, 470, 70, 480, 110, 600, 350, 500);
    quad(624, 470, 629, 480, 589, 600, 350, 500);
    fill(219, 190, 140); //skin
    ellipse(350, 450, 500);
    quad(100, 450, 350, 450, 350, 850, 140, 750);
    quad(600, 450, 350, 450, 350, 850, 560, 750);
    fill(54, 36, 28); //eyebrows
    quad(300, 400, 200, 385, 150, 410, 300, 425);
    quad(399, 400, 499, 385, 549, 410, 399, 425);
    stroke(54, 36, 28); //lashes
    strokeWeight(3);
    noFill();
    arc(225, 475, 95, 60, PI, TWO_PI);
    arc(474, 475, 95, 60, PI, TWO_PI);
    noStroke();
    fill(54, 36, 28); //pupils
    ellipse(225, 462, 20, 35);
    ellipse(474, 462, 20, 35);
    fill(205, 156, 127); //nose
    quad(350, 500, 300, 625, 350, 650, 400, 625);
    noFill();
    stroke(85, 4, 4); //lips
    strokeWeight(5);
    arc(350, 690, 150, 40, 0, PI);
}

Leave a Reply