diff options
author | borenet@google.com <borenet@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2012-08-28 15:15:49 +0000 |
---|---|---|
committer | borenet@google.com <borenet@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2012-08-28 15:15:49 +0000 |
commit | 0dd5ceb6d621c278ab09e97ea7e2172007990a5a (patch) | |
tree | 1cf6c4910ee3cb77923b4a3fe264b0d2718d9381 /src | |
parent | 8090e651fc1055e0a36f5f17c851faafda949b2c (diff) |
Fix ANGLE build
Review URL: https://codereview.appspot.com/6498045
git-svn-id: http://skia.googlecode.com/svn/trunk@5315 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'src')
-rw-r--r-- | src/views/win/SkOSWindow_win.cpp | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/src/views/win/SkOSWindow_win.cpp b/src/views/win/SkOSWindow_win.cpp index 038a2e85a1..150be6aa70 100644 --- a/src/views/win/SkOSWindow_win.cpp +++ b/src/views/win/SkOSWindow_win.cpp @@ -24,6 +24,12 @@ #include "gl/GrGLInterface.h" #include "GLES2/gl2.h" + +#define ANGLE_GL_CALL(IFACE, X) \ + do { \ + (IFACE)->f##X; \ + } while (false) + #endif #define INVALIDATE_DELAY_MS 200 @@ -528,17 +534,17 @@ bool SkOSWindow::attachANGLE(int msaaSampleCount) { const GrGLInterface* intf = GrGLCreateANGLEInterface(); if (intf) { - GR_GL_CALL(intf, ClearStencil(0)); - GR_GL_CALL(intf, ClearColor(0, 0, 0, 0)); - GR_GL_CALL(intf, StencilMask(0xffffffff)); - GR_GL_CALL(intf, Clear(GL_STENCIL_BUFFER_BIT |GL_COLOR_BUFFER_BIT)); + ANGLE_GL_CALL(intf, ClearStencil(0)); + ANGLE_GL_CALL(intf, ClearColor(0, 0, 0, 0)); + ANGLE_GL_CALL(intf, StencilMask(0xffffffff)); + ANGLE_GL_CALL(intf, Clear(GL_STENCIL_BUFFER_BIT |GL_COLOR_BUFFER_BIT)); } } if (eglMakeCurrent(fDisplay, fSurface, fSurface, fContext)) { const GrGLInterface* intf = GrGLCreateANGLEInterface(); if (intf ) { - GR_GL_CALL(intf, Viewport(0, 0, SkScalarRound(this->width()), + ANGLE_GL_CALL(intf, Viewport(0, 0, SkScalarRound(this->width()), SkScalarRound(this->height()))); } return true; @@ -563,7 +569,7 @@ void SkOSWindow::presentANGLE() { const GrGLInterface* intf = GrGLCreateANGLEInterface(); if (intf) { - GR_GL_CALL(intf, Flush()); + ANGLE_GL_CALL(intf, Flush()); } eglSwapBuffers(fDisplay, fSurface); |