Commit e8c566d7 authored by schultz's avatar schultz
Browse files

call glewInit, if glBindFramebufferEXT is a nullpointer

this prevents a segfault on windows. But it is only a workaround, as the
function should already be initialized at this point, but it is not
parent 4210614d
......@@ -2070,6 +2070,8 @@ void GLState::bindFramebuffer(GLenum _target, GLuint _framebuffer)
if (stateStack_.back().framebuffers_[i] != _framebuffer)
#endif
{
if (!glBindFramebufferEXT)
glewInit();
glBindFramebufferEXT(_target, _framebuffer);
stateStack_.back().framebuffers_[i] = _framebuffer;
}
......
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