Building Interactivity

Screen Shot 2017-03-17 at 14.27.06

import SimpleOpenNI.*; //kinect Library
import processing.video.Movie; //movie library…

SimpleOpenNI kinect;
boolean g_kinectMode=false;
int g_movieID=0, g_numMovies=5;
PImage g_img;
//PImage img = frames[frameCount % frames.length];

Movie[] movies = new Movie[g_numMovies];
String[] moviesAddress = {
“RedShoes.mov”, “HanBAL.mov”, “RebeccaH.mov”, “SunBvld.mov”,”peterFalk.mov”
};

PImage movie;

void setup() {
size(2024, 576);
frameRate(25);
if (g_kinectMode) {
kinect = new SimpleOpenNI(this);
kinect.enableDepth();
kinect.enableUser(SimpleOpenNI.SKEL_PROFILE_NONE); // we don’t need to track the joint position data
kinect.setMirror(true);//1 reverse the image
}
for (int i = 0 ; i<min(moviesAddress.length,moviesAddress.length,g_numMovies);i++) {
movies[i] = new Movie(this, moviesAddress[i]);

// movies[i].noLoop();
}
}

 

This is the latest version of the code which randomises the movies depending on the mouseX position. It uses the mouseX and pmouse which stores the mouse previous position.

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 )

Google photo

You are commenting using your Google 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 )

Connecting to %s