X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/2059576f48e26fd140906df607d571e362b53ab9..f86190702bb433f139dc2c335e2c551755def81f:/src/osx/core/glgrab.cpp diff --git a/src/osx/core/glgrab.cpp b/src/osx/core/glgrab.cpp index 74644b45c7..669f2ba6c4 100644 --- a/src/osx/core/glgrab.cpp +++ b/src/osx/core/glgrab.cpp @@ -39,6 +39,7 @@ #import #import +#include "wx/osx/core/private.h" #include "wx/osx/private/glgrab.h" extern CGColorSpaceRef wxMacGetGenericRGBColorSpace(); @@ -114,7 +115,6 @@ CGImageRef grabViaOpenGL(CGDirectDisplayID display, CGRect srcRect) void * data; long bytewidth; GLint width, height; - long bytes; CGLContextObj glContextObj; CGLPixelFormatObj pixelFormatObj ; @@ -156,7 +156,6 @@ CGImageRef grabViaOpenGL(CGDirectDisplayID display, CGRect srcRect) bytewidth = width * 4; // Assume 4 bytes/pixel for now bytewidth = (bytewidth + 3) & ~3; // Align to 4 bytes - bytes = bytewidth * height; // width * height /* Build bitmap context */ data = malloc(height * bytewidth);