{"id":64859,"date":"2021-09-07T11:27:29","date_gmt":"2021-09-07T15:27:29","guid":{"rendered":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/?p=64859"},"modified":"2021-09-23T20:28:38","modified_gmt":"2021-09-24T00:28:38","slug":"project-1-self-portrait-2","status":"publish","type":"post","link":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/2021\/09\/07\/project-1-self-portrait-2\/","title":{"rendered":"Project 1: Self-Portrait"},"content":{"rendered":"<!DOCTYPE html PUBLIC \"-\/\/W3C\/\/DTD HTML 4.0 Transitional\/\/EN\" \"http:\/\/www.w3.org\/TR\/REC-html40\/loose.dtd\">\n<html><body><figure class=\"wp-block-image size-large\"><img loading=\"lazy\" width=\"683\" height=\"1024\" src=\"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-content\/uploads\/2021\/09\/SelfProtrait-683x1024.png\" alt=\"\" class=\"wp-image-64881\" srcset=\"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-content\/uploads\/2021\/09\/SelfProtrait-683x1024.png 683w, https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-content\/uploads\/2021\/09\/SelfProtrait-200x300.png 200w, https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-content\/uploads\/2021\/09\/SelfProtrait-768x1152.png 768w, https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-content\/uploads\/2021\/09\/SelfProtrait-1024x1536.png 1024w, https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-content\/uploads\/2021\/09\/SelfProtrait-1365x2048.png 1365w, https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-content\/uploads\/2021\/09\/SelfProtrait-1200x1800.png 1200w, https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-content\/uploads\/2021\/09\/SelfProtrait.png 1600w\" sizes=\"(max-width: 709px) 85vw, (max-width: 909px) 67vw, (max-width: 984px) 61vw, (max-width: 1362px) 45vw, 600px\"><\/figure><p>This is what it looks like.<\/p>\n\n\n\n<p><a class=\"p5_sketch_link\" data-width=\"800\" data-height=\"1200\" href=\"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-content\/uploads\/2021\/09\/sketch-14.js\">My Project<\/a><iframe src=\"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-content\/plugins\/p5-embedder\/p5_iframe.html\" class=\"p5_exampleFrame\" width=\"800\" height=\"1200\"><\/iframe><pre class=\"language-javascript\"><code class=\"p5_editor language-javascript\">function setup() {\n    createCanvas(800, 1200);\n    background(250);\n    \/\/creates the text-box looking thing for \"2-Dimensional Me\"\n    textSize(20);\n    stroke(0);\n    strokeWeight(3);\n    fill(255, 145, 164);\n    rect(300, 40, 200, 70);\n    strokeWeight(0);\n    fill(0);\n    text(\"2-Dimensional Me\", 320, 80);\n    \/\/creates the text-box for my name\n    textSize(40);\n    fill(204, 204, 255);\n    stroke(0);\n    strokeWeight(3);\n    rect(240, 1050, 325, 75);\n    strokeWeight(0);\n    fill(20);\n    text(\"Chuong Truong\", 262.5, 1100);\n    }\n\nfunction draw() {\n    \/\/creates painting-like frame\n    fill(150, 75, 0);\n    rect(0, 0, 800, 10)\n    rect(0, 10, 10, 1180);\n    rect(790, 10, 10, 1180);\n    rect(0, 1190, 1200, 10);\n    \/\/creates base face canvas\n    strokeWeight(1);\n    fill(241, 194, 125);\n    rect(150, 300, 500, 700);\n    \/\/Creates lines that attach it to the ends of the painting frame, the 3d effect was unintensional\n    fill(2, 0, 0);\n    strokeWeight(3);\n    line(10, 10, 300, 40);\n    line(500, 40, 790, 10);\n    line(10, 75, 300, 75);\n    line(500, 75, 790, 75);\n    line(10, 150, 300, 110);\n    line(500, 110, 790, 150);\n    \/\/creates eyes\n    fill(250);\n    quad(240, 520, 290, 440, 340 ,520, 290, 600);\n    quad(460, 520, 510, 440, 560, 520, 510, 600);\n    \/\/pupils\n    fill(99, 57, 15);\n    circle(510, 520, 50);\n    circle(290, 520, 50);\n    fill(20);\n    circle(290, 520, 30);\n    circle(510, 520, 30);\n    \/\/eyelids\n    fill(241, 194, 125);\n    triangle(265, 480, 290, 440, 315, 480);\n    triangle(485, 480, 510, 440, 535, 480);\n    triangle(265, 560, 290, 600, 315, 560);\n    triangle(485, 560, 510, 600, 535, 560);\n    \/\/eyebrows\n    fill(80);\n    rect(260, 420, 60, 5);\n    rect(480, 420, 60, 5);\n    \/\/nose\n    line(400, 600, 400, 700);\n    line(400, 700, 350, 750);\n    line(400, 700, 450, 750);\n    fill(20);\n    circle(415, 740, 10);\n    circle(385, 740, 10);\n    \/\/mouth\n    fill(241, 194, 125);\n    strokeWeight(5);\n    arc(340, 780, 200, 200, HALF_PI, PI);\n    fill(20);\n    square(235, 780, 10);\n    square(340, 875, 10);\n    \/\/hair\n    triangle(150, 280, 300, 280, 100, 180);\n    triangle(250, 280, 300, 280, 200, 180);\n    triangle(280, 280, 350, 280, 230, 170);\n    triangle(320, 280, 400, 280, 450, 160);\n    triangle(400, 280, 520, 280, 580, 170);\n    triangle(530, 280, 580, 280, 700, 180);\n    triangle(580, 280, 620, 280, 650, 170);\n    triangle(600, 280, 620, 280, 670, 180);\n    triangle(620, 280, 650, 280, 710, 160);\n    triangle(100, 250, 150, 330, 150, 280);\n    triangle(650, 350, 650, 300, 700, 220);\n    rect(150, 260, 500, 100);\n    noLoop();\n}\n\n\n\n\n\n\n\n<\/code><\/pre><\/p>\n\n\n\n<p><\/p><\/body><\/html>\n","protected":false},"excerpt":{"rendered":"<p>This is what it looks like. My Project function setup() { createCanvas(800, 1200); background(250); \/\/creates the text-box looking thing for &#8220;2-Dimensional Me&#8221; textSize(20); stroke(0); strokeWeight(3); fill(255, 145, 164); rect(300, 40, 200, 70); strokeWeight(0); fill(0); text(&#8220;2-Dimensional Me&#8221;, 320, 80); \/\/creates the text-box for my name textSize(40); fill(204, 204, 255); stroke(0); strokeWeight(3); rect(240, 1050, 325, 75); strokeWeight(0); &hellip; <a href=\"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/2021\/09\/07\/project-1-self-portrait-2\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Project 1: Self-Portrait&#8221;<\/span><\/a><\/p>\n","protected":false},"author":675,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[10,56],"tags":[],"_links":{"self":[{"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-json\/wp\/v2\/posts\/64859"}],"collection":[{"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-json\/wp\/v2\/users\/675"}],"replies":[{"embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-json\/wp\/v2\/comments?post=64859"}],"version-history":[{"count":2,"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-json\/wp\/v2\/posts\/64859\/revisions"}],"predecessor-version":[{"id":66351,"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-json\/wp\/v2\/posts\/64859\/revisions\/66351"}],"wp:attachment":[{"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-json\/wp\/v2\/media?parent=64859"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-json\/wp\/v2\/categories?post=64859"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2021\/wp-json\/wp\/v2\/tags?post=64859"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}