Interactive Authoring-Imaginary Landscape

paint-project-final

This is a landscape of the mind. The black background represents the moments of sadness and of moments of no thought. The splashes of color represents thoughts of creativity and bursts of happiness. Each splash is a new universe being born in the mind of someone.

Code:

PImage img;
int blue = 0;
int red = 0;
int green = 0;
int sizeI=1;
PFont font;
void setup() {
img = loadImage(“Splash_Paint.png”);
size (1080, 720);
background (255);
}

void draw() {
noStroke();
if (mousePressed) {
imageMode (CENTER);
tint(red, green, blue, 50);
image(img, mouseX, mouseY, (width/5)+sizeI, (height/5)+sizeI );
}
if (keyPressed) {
if (key == ‘c’) {
background (255);
}
if ( key ==’B’) {
blue=blue+5;
} else if ( key == ‘R’ ) {
red=red+5;
} else if ( key == ‘G’) {
green=green+5;
} else if (key == ‘g’) {
green=green-5;
} else if (key == ‘r’) {
red=red-5;
} else if (key == ‘b’) {
blue=blue-5;
} else if (key == ‘C’) {
blue=255;
green=255;
red=255;
} else if (key == ‘V’) {
blue=0;
green=0;
red=0;
}
}
}

void keyPressed() {
if (key == CODED) {
if (keyCode == DOWN) {
sizeI=sizeI-1;
}
if (keyCode == UP) {
sizeI=sizeI+1;
}
}
}

Advertisements
This entry was posted in Non-Timebased and tagged , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s