Hey guys!
I hope you enjoy this video of me drawing myself… quite terribly, I might add. I’m not the best at drawing and apparently I can overlook filling in the skin on my face. But I’m still VERY proud of the program and the music choice from Mario Paint. It seemed fitting!
Additionally, here’s my code for this program:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 |
float lineWidth = 2; boolean mouseLine; boolean mouseEllipse; void setup() { // Set Up Digital Canvas size(800, 600); background(255); noStroke(); // Bisque Color Block fill(255, 228, 196); rect(0, 0, 50, 50); // Sky Blue Color Block fill(135, 206, 235); rect(0, 50, 50, 50); // Saddle Brown Color Block fill (139, 69, 19); rect (50, 0, 50, 50); // Black Color Block fill (0); rect (50, 50, 50, 50); // Light Coral Color Block fill (240, 128, 128); rect (0, 100, 50, 50); // Line Stroke Block stroke(0); strokeWeight (2); line (5, 300, 45, 350); // Circle Stroke Block noFill(); ellipse (77, 325, 50, 50); // Set Stroke Color to Black Line stroke(0); mouseLine = true; } void draw(){ // Click to change colors if (mousePressed && mouseX <= 50 && mouseY <= 50){ stroke(255, 228, 196); } if (mousePressed && mouseX <= 50 && mouseY >= 50 && mouseY <= 100){ stroke(135, 206, 235); } if (mousePressed && mouseX > 50 && mouseX <= 100 && mouseY <= 50){ stroke(139, 69, 19); } if (mousePressed && mouseX > 50 && mouseX <= 100 && mouseY > 50 && mouseY <= 100){ stroke(0); } if (mousePressed && mouseX >= 0 && mouseX <= 50 && mouseY > 100 && mouseY <= 150){ stroke (240, 128, 128); } //Click to change Draw Shape if (mousePressed && mouseX >= 5 && mouseX <= 45 && mouseY >= 300 && mouseY <= 350){ mouseLine = true; mouseEllipse = false; } if (mousePressed && mouseX >= 52 && mouseX <= 132 && mouseY >= 300 && mouseY <= 350){ mouseLine = false; noStroke(); mouseEllipse = true; } // Tell what to draw if(mousePressed && mouseButton == LEFT && mouseLine == true){ line(mouseX, mouseY, pmouseX, pmouseY); } if(mousePressed && mouseButton == LEFT && mouseEllipse == true){ ellipse(mouseX, mouseY, 150, 150 ); } // Set the stroke weight strokeWeight(lineWidth); } void keyPressed(){ // Increase lineWidth if (key == '+') { lineWidth++; } // Decrease lineWidth if (key == '-') { lineWidth--; if (lineWidth <= 0){ lineWidth = 1; } } // Reset Digital Canvas if (key == ' ') { // Set Up Digital Canvas size(800, 600); background(255); noStroke(); // Bisque Color Block fill(255, 228, 196); rect(0, 0, 50, 50); // Sky Blue Color Block fill(135, 206, 235); rect(0, 50, 50, 50); // Saddle Brown Color Block fill (139, 69, 19); rect (50, 0, 50, 50); // Black Color Block fill (0); rect (50, 50, 50, 50); // Light Coral Color Block fill (240, 128, 128); rect (0, 100, 50, 50); // Line Stroke Block stroke(0); fill (0); strokeWeight (2); line (5, 300, 45, 350); // Circle Stroke Block noFill(); ellipse (77, 325, 50, 50); // Set Stroke Color to Black Line stroke(0); mouseLine = true; mouseEllipse = false; } } |
One response to “Self Portrait (With a Nice Soundtrack!)”