当前位置: 首页>>代码示例>>C++>>正文


C++ Tracker::setTrackerLength方法代码示例

本文整理汇总了C++中Tracker::setTrackerLength方法的典型用法代码示例。如果您正苦于以下问题:C++ Tracker::setTrackerLength方法的具体用法?C++ Tracker::setTrackerLength怎么用?C++ Tracker::setTrackerLength使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Tracker的用法示例。


在下文中一共展示了Tracker::setTrackerLength方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: resetCam

FFTTracer::FFTTracer(){
    fft_size = ((testApp*)ofGetAppPtr())->fft_size;
    magnitude = new float[fft_size];
    
    for (int i = 0; i < fft_size; i++) {
        ofVec3f p = ofVec3f(0, 0, 0);
        pos.push_back(p);
        ofVec3f v = ofVec3f(0, 0, 0);
        vel.push_back(v);
        
        Tracker *t = new Tracker;
        t->setup();
        t->setTrackerLength(10);
        trackers.push_back(t);
    }
    
    //ばねパラメータ
    /*
     stiffness = 1.0;
     damping = 0.9;
     mass = 100.0;
     */
    stiffness = 2.0;
    damping = 0.92;
    mass = 200;
    
    //((testApp*)ofGetAppPtr())->cam.setPosition(0, 0, -200);
    //((testApp*)ofGetAppPtr())->cam.lookAt(ofVec3f(0,0,0));
    //camStart = ofPoint(0,0,-200);
    //camEnd = camStart;
    resetCam();
}
开发者ID:bimyoo,项目名称:AudioVisualApps,代码行数:32,代码来源:FFTTracer.cpp

示例2: setup

//--------------------------------------------------------------
void ofApp::setup() {
	ofSetFrameRate(60);
	ofSetVerticalSync(true);
	
	rotate = 0;
	
	// setup bvh
	bvh[0].load("bvhfiles/kashiyuka.bvh");
	bvh[1].load("bvhfiles/nocchi.bvh");
	bvh[2].load("bvhfiles/aachan.bvh");
	
	for (int i = 0; i < 3; i++)	{
		bvh[i].play();
	}
	
	track.loadSound("Perfume_globalsite_sound.wav");
	track.play();
	track.setLoop(true);
	
	// setup tracker and drawer
	for (int i = 0; i < 3; i++)
		{
		ofxBvh &b = bvh[i];
		Drawer *d = new Drawer;
		
		for (int n = 0; n < b.getNumJoints(); n++) {
			const ofxBvhJoint *o = b.getJoint(n);
			Tracker *t = new Tracker;
			t->setup(o);
			t->setTrackerLength(trackerLength);
			trackers.push_back(t);
			d->add(o);
		}
		
		drawers.push_back(d);
		}
	
	ofPushMatrix();
	ofTranslate(0, -100);
	ofScale(1, 1, 1);
	ofRotateX(90);
	camera.setFov(90);
	camera.lookAt(ofVec3f(0,0,0));
	camera.setPosition(300, 30, 300);
	//camera.disableMouseInput();
	ofPopMatrix();
	background.loadImage("background.png");
	
}
开发者ID:Kajiyu,项目名称:LiTLeaders7_MArt,代码行数:50,代码来源:ofApp.cpp

示例3: setup

//--------------------------------------------------------------
void ofApp::setup() {
	ofSetFrameRate(60);
	ofSetVerticalSync(true);	
	
	rotate = 0;
	
	// setup bvh
	bvh[0].load("bvhfiles/kashiyuka.bvh");
	bvh[1].load("bvhfiles/nocchi.bvh");
	bvh[2].load("bvhfiles/aachan.bvh");
	
	for (int i = 0; i < 3; i++)	{
		bvh[i].play();
	}
	
	track.load("Perfume_globalsite_sound.wav");
	track.play();
	track.setLoop(true);
	
	// setup tracker
	for (int i = 0; i < 3; i++)
	{
		ofxBvh &b = bvh[i];
		
		for (int n = 0; n < b.getNumJoints(); n++) {
			const ofxBvhJoint *o = b.getJoint(n);
			Tracker *t = new Tracker;
			t->setup(o);
			t->setTrackerLength(trackerLength);
			trackers.push_back(t);
		}
	}
	
	camera.setFov(45);
	camera.setDistance(360);
	camera.disableMouseInput();
	
	background.load("background.png");
	
}
开发者ID:MorimasaAketa,项目名称:perfume-bvh-oF,代码行数:41,代码来源:ofApp.cpp


注:本文中的Tracker::setTrackerLength方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。