Use NSOpenGLProfileVersion3_2Core for any OpenGL 3.2+ version.

This commit is contained in:
Ioannis Tsakpinis 2014-05-02 23:00:44 +03:00
parent 132ff0191d
commit 50c0c30499
1 changed files with 3 additions and 3 deletions

View File

@ -45,10 +45,10 @@ import org.lwjgl.LWJGLUtil;
abstract class MacOSXPeerInfo extends PeerInfo {
MacOSXPeerInfo(PixelFormat pixel_format, ContextAttribs attribs, boolean use_display_bpp, boolean support_window, boolean support_pbuffer, boolean double_buffered) throws LWJGLException {
super(createHandle());
boolean gl32 = attribs != null && attribs.getMajorVersion() == 3 && attribs.getMinorVersion() == 2 && attribs.isProfileCore();
boolean gl32 = attribs != null && (3 < attribs.getMajorVersion() || (attribs.getMajorVersion() == 3 && 2 <= attribs.getMinorVersion())) && attribs.isProfileCore();
if ( gl32 && !LWJGLUtil.isMacOSXEqualsOrBetterThan(10, 7) )
throw new LWJGLException("OpenGL 3.2 requested, but it requires MacOS X 10.7 or newer");
throw new LWJGLException("OpenGL 3.2+ requested, but it requires MacOS X 10.7 or newer");
choosePixelFormat(pixel_format, gl32, use_display_bpp, support_window, support_pbuffer, double_buffered);
}