Concept:
The concept of my first assignment is to use JavaScript (p5) to code 2D primitive shapes to create a self-portrait. This involves carefully selecting the correct shapes and inputs (x-axis, y-axis, etc.), as well as determining how to fill shapes with color, and choosing the color and size of the shape strokes to achieve the final look.
In my self-portrait, I included two elements that are important to me. The first element is the night sky and the moon, as my favorite time of day is nighttime. The second element is the eyes, which hold significance because I have a twin (we are not biologically identical), but people often confuse us. To help others distinguish between us, I always suggest looking at our eye colors—I have greenish-grey eyes, while my twin has brown eyes.
Highlighted code:
I am proud of the final outcome I achieved, but I am especially proud of the eyes. I successfully layered different sizes of circles with various colors, perfectly centering them on top of each other. I am also proud of the eyelashes, as I was able to align them symmetrically opposite each other with the same length and size.
//eyes fill(255); circle(165,175,37); circle(235,175,37); fill('rgb(87,107,136)'); circle(165,175,27); circle(235,175,27); fill(0); circle(165,175,15); circle(235,175,15); stroke(0); strokeWeight(2); line(147,170,140,165); line(150,165,143,160); line(153,160,146,155); line(253,170,260,165); line(250,165,257,160); line(247,160,254,155);
Sketch:
Future Improvements:
In the future I would like to animate my work (example: make the eyes move), and I would like to learn how to draw curved lines (for example to learn how to draw the eyebrows).