diff options
| author | Tim Redfern <tim@eclectronics.org> | 2012-03-31 16:44:02 +0100 |
|---|---|---|
| committer | Tim Redfern <tim@eclectronics.org> | 2012-03-31 16:44:02 +0100 |
| commit | 0e8f0361c1068eb4c2f634dfcf4e1762d87f40d2 (patch) | |
| tree | 96a4eb154c1ac2dbe5ad4e04d4e33b281832e441 /morpher/src/testApp.cpp | |
| parent | 623e1924aeea83ea70c8ae7f645b067f17a293ea (diff) | |
implementing trap door
Diffstat (limited to 'morpher/src/testApp.cpp')
| -rw-r--r-- | morpher/src/testApp.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/morpher/src/testApp.cpp b/morpher/src/testApp.cpp index 41b04eb..3b5779e 100644 --- a/morpher/src/testApp.cpp +++ b/morpher/src/testApp.cpp @@ -28,8 +28,11 @@ void testApp::update(){ void testApp::draw(){ //calculate morph targets float segment=(sin(ofGetElapsedTimef())*0.5)+0.5; + vector<int> targets; vector<float> weights; + targets.push_back(0); weights.push_back(segment); + targets.push_back(1); weights.push_back(1.0-segment); //printf("drawing %f %f\n",segment,1.0-segment); @@ -41,7 +44,7 @@ void testApp::draw(){ ofRotate(yr,1,0,0); ofRotate(180,1,0,0); ofScale(2.0,2.0,2.0); - mesh.draw(weights); + mesh.draw(targets,weights); ofPopMatrix(); unbindTexture(texture); |
