summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2013-02-21 09:35:05 +0100
committerSven Gothel <[email protected]>2013-02-21 09:35:05 +0100
commit97401c4b832aa6f65bfbad47c54d18e4b720dbce (patch)
treef4a3cd9617e50a632632255709ea926fe5bc4e15 /src
parent24fe89e6d7cc551aaffb6c95624271eef027b275 (diff)
Relax GLContextImpl.setGLFunctionAvailability(..)'s Version Matching if testing major < 3 versions. (Bug 679)
On OSX, we 'only' support the ctx ARB creation and hence have no !ARM fallback. If querying a version [2.0 .. 3.0] for GL2, it is acceptable if a valid OpenGL version is lower, e.g. 1.4.
Diffstat (limited to 'src')
-rw-r--r--src/jogl/classes/jogamp/opengl/GLContextImpl.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/jogl/classes/jogamp/opengl/GLContextImpl.java b/src/jogl/classes/jogamp/opengl/GLContextImpl.java
index e279c0423..98b9ede36 100644
--- a/src/jogl/classes/jogamp/opengl/GLContextImpl.java
+++ b/src/jogl/classes/jogamp/opengl/GLContextImpl.java
@@ -1301,7 +1301,7 @@ public abstract class GLContextImpl extends GLContext {
// Only validate if a valid int version was fetched, otherwise cont. w/ version-string method -> 3.0 > Version || Version > MAX!
if ( GLContext.isValidGLVersion(glIntMajor[0], glIntMinor[0]) ) {
if( glIntMajor[0]<major || ( glIntMajor[0]==major && glIntMinor[0]<minor ) || 0 == major ) {
- if( strictMatch && 0 < major ) {
+ if( strictMatch && 2 < major ) { // relaxed match for versions major < 3 requests, last resort!
if(DEBUG) {
System.err.println(getThreadName() + ": GLContext.setGLFuncAvail.X: FAIL, GL version mismatch (Int): "+GLContext.getGLVersion(major, minor, ctxProfileBits, null)+" -> "+glVersion+", "+glIntMajor[0]+"."+glIntMinor[0]);
}
@@ -1326,7 +1326,7 @@ public abstract class GLContextImpl extends GLContext {
// Only validate if a valid string version was fetched -> MIN > Version || Version > MAX!
if( null != strGLVersionNumber ) {
if( strGLVersionNumber.compareTo(setGLVersionNumber) < 0 || 0 == major ) {
- if( strictMatch && 0 < major ) {
+ if( strictMatch && 2 < major ) { // relaxed match for versions major < 3 requests, last resort!
if(DEBUG) {
System.err.println(getThreadName() + ": GLContext.setGLFuncAvail.X: FAIL, GL version mismatch (String): "+GLContext.getGLVersion(major, minor, ctxProfileBits, null)+" -> "+glVersion+", "+strGLVersionNumber);
}