30 lines
961 B
C++
Raw Normal View History

2012-01-24 15:13:07 +01:00
#include "ofAppGlutWindow.h"
#include "RefractiveIndex.h"
2012-02-11 18:54:46 +01:00
#include "ofxXmlSettings.h"
#define SCREEN_WIDTH 800
#define SCREEN_HEIGHT 600
////also the new shit////
2012-01-24 15:13:07 +01:00
int main() {
ofAppGlutWindow window;
2012-02-11 18:54:46 +01:00
ofxXmlSettings XML;
XML.loadFile("../data/config.refindx");
bool fullscreen = (XML.getValue("config:display:fullscreen", "true") == "true" ? true : false);
2012-02-11 18:54:46 +01:00
int screen_w = XML.getValue("config:display:width", SCREEN_WIDTH);
int screen_h = XML.getValue("config:display:height", SCREEN_HEIGHT);
cout << "> display configuration" << endl;
cout << "* fullscreen: " << (fullscreen ? "yes" : "no") << endl;
if(!fullscreen) {
cout << "* screen width: " << screen_w << endl;
cout << "* screen height: " << screen_h << endl;
}
ofSetupOpenGL(&window, screen_w, screen_h, (fullscreen ? OF_FULLSCREEN : OF_WINDOW));
2012-01-24 15:13:07 +01:00
ofRunApp(new RefractiveIndex());
}