Commit e607ba56 authored by Martin Schultz's avatar Martin Schultz
Browse files

hotfix FBO from ACG

parent 11e2239a
......@@ -86,9 +86,16 @@ FBO::
init()
{
// Create framebuffer object
if (!checkExtensionSupported("GL_EXT_framebuffer_object")) {
std::cerr << "Framebuffer object not supported! " << std::endl;
exit( 1 );
//EXT_framebuffer_object was removed in OpenGL version 3.1
//hence no core profile has the extension explicitly, but fbos
//were adopted in opengl v 3.0 so don use this extension on core profiles
if(!ACG::openGLVersion(3,0))
{
if (!checkExtensionSupported("GL_EXT_framebuffer_object")) {
std::cerr << "Framebuffer object not supported! " << std::endl;
exit( 1 );
}
}
// test whether fbo hasn't been created before
......
......@@ -113,7 +113,7 @@ public:
void attachTexture2D( GLenum _attachment,
GLsizei _width, GLsizei _height,
GLuint _internalFmt, GLenum _format,
GLint _wrapMode = GL_CLAMP,
GLint _wrapMode = GL_CLAMP_TO_EDGE,
GLint _minFilter = GL_NEAREST,
GLint _magFilter = GL_NEAREST);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment