The last couple of weeks have been truly bizarre. I was in college in 2008 during the Financial Crisis and thought it was one of the weirder and more momentous experiences I’d lived through. This moment has quickly leapfrogged 2008, and given how terrible this situation is for so many people, I’m very lucky to be in school yet again to participate in/observe how this all unfolds.
Still, it’s been difficult to focus on schoolwork during this first wave of changes to our lives, our world. Prior to going remote, I was very excited to experiment with a quad setup at school; moving from stereo to multichannel was what I signed up for! Going remote, worrying about family and friends, making major adjustments to lifestyle, and just reading the constantly shifting news has drained my motivation tank. So, this week’s assignment is basically a sketch, a set of plans for an experiment, but not what I would have liked to do in a more-normal world.
Idea:
I would like to make a p5 + tone.js sketch that functions like a spatialization test with a twist. I’ve never worked with quad, so this would be a helpful way to start to understand some of the “physics” of different audio setups. In short, the tool will play individual notes in the form of moving balls that, when played together, can form chords. The notes will play through different channels as they collide with the “speakers” on screen.
Here is a rough skeleton of the beginnings:
As I build this out, users will be able to:
Arrange a multi-channel speaker setup on the canvas
The speakers will be rectangles with inputs to indicate the channel number
Click to create notes visualized as balls that bounce around the screen
The balls carry a note that belongs to a particular key
The note is randomly chosen from the array of notes when created
Default will be to only choose 1,3,5,8 notes from the key to create a major chord
As the balls collide with the rectangles, the note associated with the ball plays through the channel associated with the speaker.
Create many balls, increasing the chance of a chord playing through different speakers
Use the the right or left arrow to change the key that the notes are drawn from.
Use the up or down arrows to make balls move faster or slower
Hit space to clear balls
Execution Plan
I started to wire up the sketch by creating objects for the balls and rectangles. I modified an earlier particle system sketch I made, and kept the system object, which may allow for some more features down the line. I haven’t connected tone yet, which is obviously the meat of this sketch. I plan on working on this over the next 2 weeks to make it work for the binaural assignment. The first set of things I need to to do:
Finish collision detection between ball and rectangle
Add tone.js to the html doc
Hard- assign channels to each speaker
Once this work, allow input to assign channel
When collision is detected, play a sound
Make sound draw from an array of possible sounds in a key
Create arrays for different keys
Allow key to be changed
Connect slider to ball speed
Re-configure keys/mouse presses to match a good UX
Create volume slider and hook up to tone