ofGLProgrammableRenderer::TYPE error

I’m trying to compile an openFrameworks project from a Makefile while walking through the shaders tutorial at http://www.openframeworks.cc/tutorials/graphics/shaders.html
The tutorial uses ofSetCurrentRenderer(ofGLProgrammableRenderer::TYPE) to set up the “fancy new renderer” but when I try to compile it I get this error.

error: could not convert ‘ofGLProgrammableRenderer::TYPE’ from ‘const string {aka const std::basic_string<char>}’ to ‘std::shared_ptr<ofBaseRenderer>’
make[1]: *** [obj/linux64/Release/src/main.o] Error 1
make[1]: Leaving directory ''

make: *** [Release] Error 2

Am I doing something wrong? I’m running ubuntu 14.04 LTS and grabbed a Makefile and config.make out of /apps/devApps/explicitRendererExample because I couldn’t find an example makefile anywhere in the examples. I have the most recent download from the git repo.

Hi, have a read of this http://blog.openframeworks.cc/post/133400454159/openframeworks-090-opengl-45 with the release of 0.9.0, they have changed way the programmable renderer is selected, so that post should show you the new syntax.

Hello @ekisu, the tutorial needs to be updated. Try to have a look in the examples folder, examples/gl/shadersExample at the main.cpp file to see how to set up your application.
This should allows you to get starting using shaders:

int main( ){
    ofGLWindowSettings settings;
    settings.setGLVersion(3, 2);  // Programmable pipeline
    settings.width = 1024;
    settings.height = 768;
    ofRunApp(new ofApp());
1 Like