Experiments in procedural animation

Procedural, generative, whatever you want to call it. I’ve been pretty fascinated by the concept since first seeing the work of Universal Everything back at university. I even had a workshop with Karsten Schmidt, who introduced me to Processing, and the general idea of writing code to create visuals.

I love the idea that you don’t really know what you’ll get, and that every time it runs there will be a different result. I love playing with tiny tweaks in the code to see what the results are. And most of all, I love creating something that a user can use to create something else.

I take inspiration too from the likes of Joshua Davis, Brendan Dawes and Saskia Freek.

It took a long time for me to finally pick up Processing, but after my introduction to programming, I guess I felt a renewed desire to experiment and play around.

If you’re not familiar, processing is a Java framework that’s purpose built for creative coding. It even comes with it’s own IDE so it’s a great introduction to programming if you’ve never done it before. There’s an endless list of things you can do with it, it’s made for experimenting.

There are 2 main methods that run within a Processing program; the “setup” and the “draw”. Setup sets the rules for the program such as the background, the size of the window etc. while the draw method runs every frame (60fps) and redraws whatever is described.

So far I’ve been focusing on visualising sound. It should come as no surprise that sound/music visualisations are an area of interest for me. I have visions of being stood next to the sound desk in an arena, playing around with custom built live visuals that dance to the music.

For now though, I wanted to see how it works. I started by building some very basic random shapes that would sweep across the screen.

Essentially, this was just creating an array and populating it with “beams” that would hold random numbers representing their length, width, colour and so on. That would then feed into a method which would iterate over the array list and create a shape based on those fields, moving each one across the screen each time the draw method is called. It’s very simple. So simple in fact that when I accidentally deleted the files (poor effort) it took virtually no time to recreate it.

From there, I decided to introduce sound. Processing comes with it’s own sound library so it’s easy to add an instruction to detect sound input from the microphone and then turn that into a floating point number. Once you’ve got that, what you do with it is up to you! I decided to extend the shapes and have their size and speed controlled by the sound levels. As well as that, I added some keyboard controls to switch different directions of particles on and off, and also to select colours.

It’s still quite basic and a bit messy, but it’s been a nice way to get an idea of how processing works. From here I need to learn how to use it within another IDE so that I can build actual classes and separate the code out (currently it’s just one long file). I’d also like to create some sort of GUI for the controls; keyboard controls are great and all but it’s a bit tricky to see what you’re doing.

Beyond that, I’ll just keep experimenting I guess. There’s so much that can be done with Processing, and it’s so easy to pick up that really the limit is your imagination (ugh cheesy I know but it’s really true)!

Share
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  

Leave a Reply

Your e-mail address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.