MLNI-Week#2 p5 drawing functions ——Lishan Qin

I used p5.js to draw the image above. The link to the code is here. I used functions like rect(), ellipse() and triangle() to draw the Totoro. Then I found the snowflake function on p5.js example. This example contributed by Aatish Bhatia uses an array of objects to hold the snowflake particles. It uses frameCount to update time and initialize the coordinates of snowflakes using functions like “this.posX=0”. I find this example to be so beautiful so I added it to my codes to create a peaceful atmosphere for my Totoro.

Leave a Reply