My Concept:
My concept was to do something with the poem “Stopping by Woods on a Snowy Evening” by Robert Frost. Since the assignment was to try displaying text, I thought it’d be good opportunity to go a step further and experiment with something new, and a lot more advanced than what I’m used to.
In the poem, there are certain lines such as “My little horse must think it queer/To stop without a farmhouse near/Between the woods and frozen lake/ The darkest evening of the year.” so I thought it’d be fun to create an image of a man with a horse at night, just like in the poem. Due to the assignment being about displaying text, I thought it’d be fun to have the image be created by text.
Poem:
Stopping by Woods on a Snowy Evening
by Robert Frost
Whose woods these are I think I know.
His house is in the village though;
He will not see me stopping here
To watch his woods fill up with snow.
My little horse must think it queer
To stop without a farmhouse near
Between the woods and frozen lake
The darkest evening of the year.
He gives his harness bells a shake
To ask if there is some mistake.
The only other sound’s the sweep
Of easy wind and downy flake.
The woods are lovely, dark and deep,
But I have promises to keep,
And miles to go before I sleep,
And miles to go before I sleep.
A highlight of code I’m proud of:
function preload(){
winter = loadImage('winter0.jpg');
txtFile = loadStrings('winter.txt'); //loads in the txt file
newFont = loadFont('ArchivoBlack-Regular.ttf'); //loads in new font
}
This feels silly to admit, but I’m honestly most proud of myself for actually figuring out the preload function. Obviously the assignment as a whole was difficult, but I had a lot of videos and resources in order to guide me through most of it. The preload function was the one thing I did not have much information on (I originally tried to put the text file and font directly onto the code without preloading it).
The worst part came after I followed the tutorial for uploading an image. For some reason, it did not work. I spent a full hour tinkering with the code and growing frustrated because no one else seemed to have the same problem I was. The code itself was perfectly fine, but no matter what I did, the program still found an error.
In the end, after looking through countless reddit posts, I learned that the reason why I couldn’t upload an image was because the current version of p5js couldn’t upload images that well, so I had to go back to version 1.4.0 in order to even begin coding. It feels stupid that that’s the part I struggled with most, but its true.
Embedded Sketch
How to program custom text and fonts in P5.js” to find a good font for the image (New Courier just didn’t look that great). Lastly, I found The Coding Train’s code about coding a specific text into ASCII in order to turn the poem into the text. (Words are spelt downwards in case you struggle to read the poem. Additionally, the image being resized also makes it hard to read).
I also had some help from random reddit posts that were struggling with the same problem as me. They weren’t the most helpful considering it took me hours to find a solution for the image thing, and also did not help me find a solution as to why the code kept being considered an infinite loop, but it was at least a nice resource to have.
Reflection:
As fun as this was to make, I wish I wasn’t so reliant on tutorials when making it. Obviously it would be harder considering I was making something a little more advanced, but it just felt annoying that anytime I wanted to try something new with the code I couldn’t because of fear I’d mess it up too much. I enjoy actually exploring things with the code, and this specific code felt too complex for me to even try tweaking it too much. It was a fun experience overall though.


