Sprint 9- retrospective-Lukundu

Nearing the end of the build, we’re adding and combining all the visual elements. I worked on refining the user interaction and updating the fire particle effect.

The user interaction as discussed in the last sprint was based on point line distance. I found a better way to get more accurate distance across all the tracked joints.


float ofApp::getDist(ofVec2f a, ofVec2f b, ofVec2f rv) {

//ofVec2f line = b - a;
//ofVec2f lp = a - rv;
//ofVec2f c = line * line.dot(lp) / line.dot(line);
//ofVec2f d = lp - c;

//return d.dot(d);

ofVec2f ab = a - b;
float line = ab.lengthSquared();
float t = ofClamp((rv-a).dot((b-a))/line,0,1);
ofVec2f dp = a + t* (b - a);

return rv.distance(dp);

}

One problem I ran into was that calculation needed to be inside the kinect track class. Otherwise, the user reference overwrites the tracking point for the second user.

Referencing The Nature of code, by Daniel Shiffman I added perlin nosie to the fire, to give the look of embers flying off as the fire dies.

float time = ofGetElapsedTimef();
float x = ofRandom(-1,1)*position.x*ofNoise(time-50);
float y = ofRandom(-1,1)*position.y*ofNoise(time+80);
x *= 0.001;
y *= 0.001;
ofTranslate(position.x, position.y);
applyForce(ofVec2f(x, y));


In the final sprints, I’ll be refining more of the code and polishing off the interaction, we’ll hold user testing over the week to better adapt the installation.

Advertisements

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