diff --git a/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLGraphicsConfiguration.java b/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLGraphicsConfiguration.java index 0985432ce5..fa8e8d468f 100644 --- a/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLGraphicsConfiguration.java +++ b/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLGraphicsConfiguration.java @@ -234,7 +234,7 @@ private static GLCapabilities PixelFormat2GLCapabilities(GLProfile glp, long pix } else { off = 0; } - attrToken.position(1); + attrToken.position(off); final int len = attrToken.remaining(); final IntBuffer ivalues = Buffers.newDirectIntBuffer(len); @@ -251,6 +251,7 @@ private static GLCapabilities PixelFormat2GLCapabilities(GLProfile glp, long pix } else { CGL.CGLQueryPixelFormat(pixelFormat, attrToken, len, ivalues); } + if(null == glp && MacOSXCGLContext.isLionOrLater) { // pre-scan for OpenGL Profile for (int i = 0; i < len; i++) {