Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/kalwalt/ofxskybox
openFramework addon for a skybox object
https://github.com/kalwalt/ofxskybox
ofxskybox openframeworks openframeworks-addon skybox
Last synced: about 1 month ago
JSON representation
openFramework addon for a skybox object
- Host: GitHub
- URL: https://github.com/kalwalt/ofxskybox
- Owner: kalwalt
- License: mit
- Created: 2011-12-20T19:51:38.000Z (almost 13 years ago)
- Default Branch: master
- Last Pushed: 2022-05-13T04:57:39.000Z (over 2 years ago)
- Last Synced: 2024-04-17T02:23:20.924Z (7 months ago)
- Topics: ofxskybox, openframeworks, openframeworks-addon, skybox
- Language: C++
- Homepage:
- Size: 1.55 MB
- Stars: 7
- Watchers: 2
- Forks: 5
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ofxSkyBox
A simple ofxAddon to display a SkyBox object in an openFrameworks scene.
## Setup
You need to instantiate in the header an ofxSkyBox, an ofCamera and an ofSphereCenter.
Then in the setup():
set the sphereCenter, the ofCamera position and load the ofxSkyBox instance.
```
void testApp::setup(){sphereCenter = ofVec3f(0, 0, 0);
camera.setPosition(ofVec3f(0, 0, 0));
skybox.load();
}
```in draw():
between the camera begin/end update the skybox and the lookAt vector.
```
void testApp::draw(){camera.begin();
skybox.draw();
camera.lookAt(ofVec3f(mouseY, 0,mouseX), ofVec3f(0, 1, 0));
camera.end();
}
```
## Tested
Tested with openFrameworks 0.11.0.