Skip to content
Permalink
Browse files

Port ec7e78d to the OS X overlay.

  • Loading branch information...
mkrautz committed Feb 5, 2015
1 parent 403aedb commit 8e3168b2e796a16fcd7b1e53a22b1a228ffcdc69
Showing with 6 additions and 1 deletion.
  1. +6 −1 macx/overlay/overlay.m
@@ -559,16 +559,21 @@ static void drawContext(Context * ctx, int width, int height) {
glEnableClientState(GL_VERTEX_ARRAY);
glEnableClientState(GL_TEXTURE_COORD_ARRAY);

int bound = 0;
int bound = 0, vbobound = 0;
glGetIntegerv(GL_PIXEL_UNPACK_BUFFER_BINDING, &bound);
glGetIntegerv(GL_ARRAY_BUFFER_BINDING, &vbobound);

if (bound != 0)
glBindBuffer(GL_PIXEL_UNPACK_BUFFER_ARB, 0);
if (vbobound != 0)
glBindBuffer(GL_ARRAY_BUFFER, 0);

drawOverlay(ctx, width, height);

if (bound != 0)
glBindBuffer(GL_PIXEL_UNPACK_BUFFER_ARB, bound);
if (vbobound != 0)
glBindBuffer(GL_ARRAY_BUFFER, vbobound);

glMatrixMode(GL_TEXTURE);
glPopMatrix();

0 comments on commit 8e3168b

Please sign in to comment.
You can’t perform that action at this time.