Generative Visuals
01Aug11
Inspired by Carsten Nicolai’s Grid Index and Moire Index, and the ambient dynamic screens of Brian Eno, I have been working on creating some generative animations based on simple sinewave manipulations. In this case, a sinewave algorithm manipulates the greyscale value of each pixel in the animation. A secondary sinewave algorithm manipulates the phase position of the first sinewave, as a result producing these very intricate repeat-patterns.
View the animation online here.
Read on for sourcecode
/*henderson[###]*/
float time;
void setup() {
size(470, 360);
}
void draw() {
background(255);
loadPixels();
for (int i=1; i<width-1; i++) {
for (int j=1; j<height-1; j++) {
pixels[j*width+i] = color(sineWave(255, i*j, 10, sineWave(155, i*j, 10, time)));
}
}
updatePixels();
time+=0.001;
}
float sineWave(float a, float t, float freq, float phase) {
float sine = (a*(sin(radians(freq*t)+phase)));
sine = map(sine, -a, a, 0, a);
return sine;
}
Filed under: Generative | Leave a Comment
Tags: generative, openprocessing, processing










No Responses Yet to “Generative Visuals”