diff options
author | Sven Gothel <[email protected]> | 2014-10-02 00:28:18 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2014-10-02 00:28:18 +0200 |
commit | 5d3caefa4ded044b2965d7e046e9c9fa35d58810 (patch) | |
tree | b74d842f338a71a9eda44312fe0ba8a7a6443e91 | |
parent | 6187fbc0a9ca9bd5140a3082013044f3294a8c6d (diff) | |
parent | 99f91f8b28d42cdf341533736e878056bcae4708 (diff) |
Merge remote-tracking branch 'gouessej/master'
3 files changed, 28 insertions, 4 deletions
diff --git a/src/jogl/classes/com/jogamp/opengl/GLRendererQuirks.java b/src/jogl/classes/com/jogamp/opengl/GLRendererQuirks.java index e8039edf1..a0a7021ac 100644 --- a/src/jogl/classes/com/jogamp/opengl/GLRendererQuirks.java +++ b/src/jogl/classes/com/jogamp/opengl/GLRendererQuirks.java @@ -340,9 +340,25 @@ public class GLRendererQuirks { * </p> */ public static final int BuggyColorRenderbuffer = 18; + + /** + * Some Intel drivers under Windows wrongly claims to support pbuffers + * with accumulation buffers. Then, the creation of a pbuffer fails: + * javax.media.opengl.GLException: pbuffer creation error: Couldn't find a suitable pixel format + * <p> + * Appears on: + * <ul> + * <li>GL_VENDOR Intel</li> + * <li>GL_RENDERER Intel Bear Lake B</li> + * <li>GL_VERSION 1.4.0 - Build 8.14.10.1930</li> + * </ul> + * + * </p> + */ + public static final int NoPBufferWithAccum = 19; /** Return the number of known quirks. */ - public static final int getCount() { return 19; } + public static final int getCount() { return 20; } private static final String[] _names = new String[] { "NoDoubleBufferedPBuffer", "NoDoubleBufferedBitmap", "NoSetSwapInterval", "NoOffscreenBitmap", "NoSetSwapIntervalPostRetarget", "GLSLBuggyDiscard", @@ -350,7 +366,7 @@ public class GLRendererQuirks { "NeedCurrCtx4ARBPixFmtQueries", "NeedCurrCtx4ARBCreateContext", "NoFullFBOSupport", "GLSLNonCompliant", "GL4NeedsGL3Request", "GLSharedContextBuggy", "GLES3ViaEGLES2Config", "SingletonEGLDisplayOnly", - "NoMultiSamplingBuffers", "BuggyColorRenderbuffer" + "NoMultiSamplingBuffers", "BuggyColorRenderbuffer", "NoPBufferWithAccum" }; private static final IdentityHashMap<String, GLRendererQuirks> stickyDeviceQuirks = new IdentityHashMap<String, GLRendererQuirks>(); diff --git a/src/jogl/classes/jogamp/opengl/GLContextImpl.java b/src/jogl/classes/jogamp/opengl/GLContextImpl.java index 01478a422..02557b7e1 100644 --- a/src/jogl/classes/jogamp/opengl/GLContextImpl.java +++ b/src/jogl/classes/jogamp/opengl/GLContextImpl.java @@ -1841,6 +1841,13 @@ public abstract class GLContextImpl extends GLContext { quirks.addQuirk( quirk ); } } + if (glVendor.equals("Intel") && glRenderer.equals("Intel Bear Lake B")) { + final int quirk = GLRendererQuirks.NoPBufferWithAccum; + if(DEBUG) { + System.err.println("Quirk: "+GLRendererQuirks.toString(quirk)+": cause: OS "+Platform.getOSType()+", [Vendor "+glVendor+" and Renderer "+glRenderer+"]"); + } + quirks.addQuirk( quirk ); + } } else if( Platform.OSType.ANDROID == Platform.getOSType() ) { // // ANDROID diff --git a/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLGraphicsConfiguration.java b/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLGraphicsConfiguration.java index 465b5f560..ee868b1c0 100644 --- a/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLGraphicsConfiguration.java +++ b/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLGraphicsConfiguration.java @@ -50,6 +50,7 @@ import javax.media.opengl.GLProfile; import com.jogamp.common.nio.Buffers; import com.jogamp.nativewindow.MutableGraphicsConfiguration; +import com.jogamp.opengl.GLRendererQuirks; import jogamp.nativewindow.windows.DWM_BLURBEHIND; import jogamp.nativewindow.windows.GDI; @@ -476,10 +477,10 @@ public class WindowsWGLGraphicsConfiguration extends MutableGraphicsConfiguratio } iattributes.put(niattribs++, WGLExt.WGL_DEPTH_BITS_ARB); iattributes.put(niattribs++, caps.getDepthBits()); - if (caps.getAccumRedBits() > 0 || + if (!sharedResource.getRendererQuirks().exist(GLRendererQuirks.NoPBufferWithAccum) && (caps.getAccumRedBits() > 0 || caps.getAccumGreenBits() > 0 || caps.getAccumBlueBits() > 0 || - caps.getAccumAlphaBits() > 0) { + caps.getAccumAlphaBits() > 0)) { iattributes.put(niattribs++, WGLExt.WGL_ACCUM_BITS_ARB); iattributes.put(niattribs++, ( caps.getAccumRedBits() + caps.getAccumGreenBits() + |