Homework using poseNet
https://glitch.com/edit/#!/drawing-rainbow-nose?path=script.js%3A1%3A0
This concept was little more frustrating and hard for me to figure out then other concepts from the semester. It took lots of remixing and trial and error with figuring out how to make the objects follow the body parts. It was mostly difficult because after watching many YouTube videos of examples, it seemed that everyone had a different way of using poseNet in their code. Specifically, it was hard to understand how the computer knows the position of the x & y values of a specific body part. The amplification part of the code was alot of trial and error because I had to change it to find the right number to make it look like the user is drawing because most of the time the circle was not following the nose or anywhere near it. The other aspect of the code that may not look like much but took me a while to figure out is the position of the text. This is because I am not used to making the canvas size the entire window width and height. However, when I tried to change the canvas size to a certain pixel size, the video did not look right. The reason I tried to change it was because I wanted to certain the text in the middle of the frame and the text align was not working for me. By giving it a specific pixel assignment didn't work because everyone's window size is different so it never looked good. However, after moving around the text, it took me while until I though about the way I could just do windowWidth/2 so it is always on the center of the frame. I tried to add other features to drawing such as that it only draws whenever the user is pressing on the mouse so it requires more interaction. I also really liked the rainbow look of the line by using the random function. I hope in the future to experiment more with different body parts but I kept it with using the nose because the x & y locations were confusing to me and I figured that keeping with the nose will be helpful because most users are not standing up.
Comments
Post a Comment