Commit eefa1ada authored by Ken Martin's avatar Ken Martin

try fixing an opengl es3 issue

glDrawBuffer is not in es3, needs to be glDrawBuffers
parent 81e29367
......@@ -582,7 +582,7 @@ void vtkOpenGLState::vtkglDrawBuffer(unsigned int val)
#endif
{
this->CurrentState.DrawBinding.DrawBuffers[0] = val;
::glDrawBuffer(val);
::glDrawBuffers(1, this->CurrentState.DrawBinding.DrawBuffers);
}
// change all stack entries for the same framebuffer
......@@ -1259,7 +1259,9 @@ void vtkOpenGLState::Initialize(vtkOpenGLRenderWindow *)
::glBindFramebuffer(GL_DRAW_FRAMEBUFFER, this->CurrentState.DrawBinding.GetBinding());
::glBindFramebuffer(GL_READ_FRAMEBUFFER, this->CurrentState.ReadBinding.GetBinding());
::glDrawBuffer(this->CurrentState.DrawBinding.GetDrawBuffer(0));
unsigned int vals[1];
vals[0] = this->CurrentState.DrawBinding.GetDrawBuffer(0);
::glDrawBuffers(1, vals);
::glReadBuffer(this->CurrentState.ReadBinding.GetReadBuffer());
}
......
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