Skip to content

Instantly share code, notes, and snippets.

@tgfrerer
Last active December 18, 2015 13:18
Show Gist options
  • Save tgfrerer/5788649 to your computer and use it in GitHub Desktop.
Save tgfrerer/5788649 to your computer and use it in GitHub Desktop.
init programmable GL renderer in openFrameworks
#include "ofMain.h"
#include "testApp.h"
#include "ofGLProgrammableRenderer.h"
//========================================================================
int main( ){
ofPtr<ofBaseRenderer> renderer(new ofGLProgrammableRenderer(false));
ofSetCurrentRenderer(renderer, false);
ofSetupOpenGL(1024,768, OF_WINDOW); // <-------- setup the GL context
testApp * app = new testApp;
// this kicks off the running of my app
// can be OF_WINDOW or OF_FULLSCREEN
// pass in width and height too:
ofRunApp( app);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment