aboutsummaryrefslogtreecommitdiffstats
path: root/src/jogl/classes/jogamp/opengl/egl/EGLGraphicsConfiguration.java
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2011-10-08 02:17:56 +0200
committerSven Gothel <[email protected]>2011-10-08 02:17:56 +0200
commit727c697f6808caec2fcbcc35d155552590d4f869 (patch)
treed28a78a95bb871f46816481ca84ba0476f39647a /src/jogl/classes/jogamp/opengl/egl/EGLGraphicsConfiguration.java
parentda279187e375fdc87ed3a73480c5548602d3454e (diff)
EGL: Fall back to NV_coverage_sample if EGL MSAA/FSAA is n/a
Diffstat (limited to 'src/jogl/classes/jogamp/opengl/egl/EGLGraphicsConfiguration.java')
-rw-r--r--src/jogl/classes/jogamp/opengl/egl/EGLGraphicsConfiguration.java11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/jogl/classes/jogamp/opengl/egl/EGLGraphicsConfiguration.java b/src/jogl/classes/jogamp/opengl/egl/EGLGraphicsConfiguration.java
index 14e67a2c1..5f241a1d0 100644
--- a/src/jogl/classes/jogamp/opengl/egl/EGLGraphicsConfiguration.java
+++ b/src/jogl/classes/jogamp/opengl/egl/EGLGraphicsConfiguration.java
@@ -217,6 +217,17 @@ public class EGLGraphicsConfiguration extends DefaultGraphicsConfiguration imple
caps.setSampleBuffers(val.get(0)>0?true:false);
caps.setNumSamples(val.get(0));
}
+ if(!caps.getSampleBuffers()) {
+ // try NV_coverage_sample extension
+ if(EGL.eglGetConfigAttrib(display, config, EGLExt.EGL_COVERAGE_BUFFERS_NV, val)) {
+ if(val.get(0)>0 &&
+ EGL.eglGetConfigAttrib(display, config, EGLExt.EGL_COVERAGE_SAMPLES_NV, val)) {
+ caps.setUseNV_coverage_sample(true);
+ caps.setSampleBuffers(true);
+ caps.setNumSamples(val.get(0));
+ }
+ }
+ }
if(EGL.eglGetConfigAttrib(display, config, EGL.EGL_TRANSPARENT_TYPE, val)) {
caps.setBackgroundOpaque(val.get(0) != EGL.EGL_TRANSPARENT_RGB);
}