Merge pull request #583 from mapbox/glx-undef-none

repair undef None GLX wrapper, pass 0 instead of None to GLX functions
This commit is contained in:
Mike Morris
2014-11-11 14:55:03 -05:00
3 changed files with 4 additions and 4 deletions

View File

@@ -5,7 +5,7 @@
#define MBGL_USE_CGL 1
#else
#define GL_GLEXT_PROTOTYPES
#include <GL/glx.h>
#include <mbgl/platform/default/glx.h>
#define MBGL_USE_GLX 1
#endif

View File

@@ -48,7 +48,7 @@ HeadlessDisplay::HeadlessDisplay() {
// We're creating a dummy pbuffer anyway that we're not using.
static int pixelFormat[] = {
GLX_DRAWABLE_TYPE, GLX_PBUFFER_BIT,
None
0
};
int configs = 0;

View File

@@ -107,7 +107,7 @@ GLXContext createCoreProfile(Display *dpy, GLXFBConfig fbconfig) {
const int context_flags[] = {
GLX_CONTEXT_MAJOR_VERSION_ARB, core_profile_versions[i].major,
GLX_CONTEXT_MINOR_VERSION_ARB, core_profile_versions[i].minor,
None
0
};
ctx = glXCreateContextAttribsARB(dpy, fbconfig, 0, True, context_flags);
if (context_creation_failed) {
@@ -172,7 +172,7 @@ void HeadlessView::createContext() {
int pbuffer_attributes[] = {
GLX_PBUFFER_WIDTH, 8,
GLX_PBUFFER_HEIGHT, 8,
None
0
};
glx_pbuffer = glXCreatePbuffer(x_display, fb_configs[0], pbuffer_attributes);
#endif