[LWJGL] try to force as GL 2.1

This commit is contained in:
Duy Tran Khanh committed 2021-01-02 18:32:15 +07:00
1 parent 4fa95b6726
commit 77841af1b9
1 file changed
+9 -3
@@ -384,10 +384,16 @@ public final class GL {
throw new IllegalStateException("There is no OpenGL context current in the current thread.");
}
APIVersion apiVersion = apiParseVersion(versionString);
try {
APIVersion apiVersion = apiParseVersion(versionString);
majorVersion = apiVersion.major;
minorVersion = apiVersion.minor;
majorVersion = apiVersion.major;
minorVersion = apiVersion.minor;
} catch (IllegalArgumentException e) {
e.printStackTrace();
majorVersion = 2;
minorVersion = 1;
}
}
}