Skip to content

Instantly share code, notes, and snippets.

@touyou
Created August 10, 2017 23:42
Show Gist options
  • Save touyou/d32fce09e58664254b58d155692ccceb to your computer and use it in GitHub Desktop.
Save touyou/d32fce09e58664254b58d155692ccceb to your computer and use it in GitHub Desktop.
ofxSceneManagerを使って時間ごとにシーンを切り替えるMusicVideo的なものを作るイメージ
void testApp::setup() {
sceneManager.addScene(ofPtr<ofxScene>(new FirstScene));
sceneManager.addScene(ofPtr<ofxScene>(new SecondScene));
sceneManager.addScene(ofPtr<ofxScene>(new ThirdScene));
sceneManager.addScene(ofPtr<ofxScene>(new ForthScene));
sceneManager.scenes.at(0)->setSceneDuration(0.0, 10.0,0.0);
sceneManager.scenes.at(1)->setSceneDuration(0.0, 7.0,0.0);
sceneManager.scenes.at(2)->setSceneDuration(0.0, 5.3,0.0);
sceneManager.scenes.at(3)->setSceneDuration(0.0, 20.0,0.0);
sceneManager.run();
}
void testApp::update() {
sceneManager.update();
}
void testApp::draw() {
sceneManager.draw();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment