Nature of Code Final

[POST INCOMPLETE]
Light forest is an interactive installation where users interact with a flashlight to explore an animated forest at night. Birds, fireflies, squirrels, owls and rabbits react to the light and to each other, either being attracted or running away.

floresta

The main code was built in Processing, exploring steering behaviors. Animations were made as png sequences and sounds added with minim library. Computer vision was written in openframeworks, sending data to the main sketch through OSC.

Code is here. Video coming soon.

Nature of Code Final

My proposal to NOC final is a playful interactive installation. The idea is to project a scene of a forest with some animals. When someone points a flashlight to the projection, animals get frightened by the light and run away (or fly, in case of birds).

During research, I found the work of Theo Watson who successfully explored forest environments and interaction with kids. Night Bright is actually pretty similar to what I proposed. I also found this Interactive Forest where users apply forces in the environment by their body movements. Pretty sweet and very naturely of code.

Interactive Forest

I’ve sketched my idea and realized I might have a problem with the light produced by the device. It should be a very focused instead of diffused. But to begin with, I’ll make my idea with mouse input. Any suggestions for interaction are welcome. Thanks!

Nature of Code Midterm 2

For my midterm, I created an environment where is possible to explode things with the mouse click. My living-room is full of objects like books, cushions, shoes and so on, that can turn into many many pixels. After a while, they return back to their original place.

1

2

3

4

5

Video:

Code is in my github.

Another cool sketch I did with the same concept:

Nature of Code Midterm 1

For Nature of Code midterm I decided to make a image deconstruction system. Basically it explodes images (or part of them) in particles. First, I did it with a png black and white image. Result is below (shot from my iPhone b/c screen capture makes it slow).

Later, I implemented the same code to a video grabber. I like the effect and I’m thinking about how to explore it further. Maybe 3D? Maybe deconstruct only few colors? Create a box2D world so the particles fall over each other? All of them together?

Forces!

For this Nature of Code week assignment, I’ve translated few examples of Nature of Code to oF. One I particularly like is the Example 1.11: Array of movers accelerating towards the mouse:

I also translated the gravity with wind, fluid resistance and gravitational attraction. You can check them in my github.

For my attraction homework, I explored several attractors trying to form a pattern (not very successful) and playing with moving attractor and some repelling forces. Videos below:

Controlled Randomness

First of all, I’ve decided to do Nature of Code assignments in openFrameworks. Not sure if that’s a good idea though. It is at least challenging. First video I’ve watched (gaussian distribution) started with a function that does not exist in oF. Therefore I’ve started my assignment looking for the code of how to calculate it.

After that, I’ve explored probability and the noise function (luckly present in oF). Red circles in the top have 80% chance to appear in the left and red circles in the bottom 80% to appear in the right. The circle in the middle changes radius in a normal distributed way and the random walker in the middle is a perlin noise walker. The result is here.

And since I wanted to explore the gaussian function in processing too, I’ve created my own circles that make a smoke (sketch below) and combining the particle system example with the noise walker, I made a Smoke Walker and a Smoke Walker towards the mouse.