Seeding Poems in the Earth (week 4)


This week’s project is really exciting to me. Setting up this kind of random output devices and then interacting with them on a weekly/daily/hourly basis fits quite snugly into my creative and living practices. I began work pretty immediately on an hourly poem generator. As I felt that the poem generation that I initially created for my iceberg project, had a lot to give when put in this kind of format.

It didn’t take too long to get a basic seeded generation device going. Here’s the logic for the seed:

print("Hello world")
function pickPoem() {
  let hourMath = hour() % 12 || 12;
  centerColor = (hourMath * 30 + minute()) % 360;
  sideColor = (centerColor + 180) % 360;

  randomSeed(year() * 1000000 + month() * 10000 + day() * 100 + hour());
  let numLines = int(hourMath);
  poem = [];
  for (let i = 0; i < numLines; i++) {
    poem.push(lines[int(random(lines.length))]);
  }

I also want to acknowledge that initially I was just going to have the poem generator use a random number between 1 and 7 for the number of lines printed every hour. I then changed my mind and wanted to have the hour of the day represented by the number of lines, I’d love feedback on how this breeds interactivity/utility or if it just makes for gobbledygook during certain hours of the day.

Another bit of interactivity I added was that the color scheme gets darker as the hour goes along. I have one of the RGB values for each color used mapped to minutes so that it grows closer to 0 as the hour goes on.

Because I was able to have an operational prototype of the sketch in a small amount of time, I challenged myself to finally host my code on a personal website. The rest of the site is still very rough and not fleshed out at all, but its really great to have a place to put my p5 sketches where I can easily reference them.

The current version of my poetry generator can be found at CowTools.art/p5/breadpoems

I would love to continue to work on this project, so any feedback would be greatly appreciated!!

Comments

Log in with itch.io to leave a comment.

The output is really lovely. I’m excited to come back and see new ones. I like the changing length. This reminds me of some of the great generated poetry in the OUTPUT book (worth checking out!).