aboutsummaryrefslogtreecommitdiffstats
path: root/src/jogl/classes/com/jogamp/opengl/GLRendererQuirks.java
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2013-05-31 11:16:01 +0200
committerSven Gothel <[email protected]>2013-05-31 11:16:01 +0200
commitcbd7bf1d65a253381b0775d57c0c949c75aef008 (patch)
tree3dc0c44cfba319fef78e17860f7fdf993e4fff7d /src/jogl/classes/com/jogamp/opengl/GLRendererQuirks.java
parentef8949d4bdfb21bbe423acc661affaf59369f859 (diff)
GLVersionNumber.createVendorVersion(): Only test match result and potentially continue matching if having a pattern-match (don't loop for-ever).
Diffstat (limited to 'src/jogl/classes/com/jogamp/opengl/GLRendererQuirks.java')
-rw-r--r--src/jogl/classes/com/jogamp/opengl/GLRendererQuirks.java42
1 files changed, 40 insertions, 2 deletions
diff --git a/src/jogl/classes/com/jogamp/opengl/GLRendererQuirks.java b/src/jogl/classes/com/jogamp/opengl/GLRendererQuirks.java
index 78bd62e42..36893f5ec 100644
--- a/src/jogl/classes/com/jogamp/opengl/GLRendererQuirks.java
+++ b/src/jogl/classes/com/jogamp/opengl/GLRendererQuirks.java
@@ -27,6 +27,8 @@
*/
package com.jogamp.opengl;
+import java.util.List;
+
/**
* GLRendererQuirks contains information of known bugs of various GL renderer.
* This information allows us to workaround them.
@@ -151,14 +153,36 @@ public class GLRendererQuirks {
*/
public static final int NeedCurrCtx4ARBCreateContext = 10;
+ /**
+ * No full FBO support, i.e. not compliant w/
+ * <ul>
+ * <li>GL_ARB_framebuffer_object</li>
+ * <li>EXT_framebuffer_object</li>
+ * <li>EXT_framebuffer_multisample</li>
+ * <li>EXT_framebuffer_blit</li>
+ * <li>EXT_packed_depth_stencil</li>
+ * </ul>.
+ * Drivers known exposing such bug:
+ * <ul>
+ * <li>Mesa <i>7.12-devel</i> on Windows with VMware <i>SVGA3D</i> renderer:
+ * <ul>
+ * <li>GL_VERSION: <i>2.1 Mesa 7.12-devel (git-d6c318e)</i> </li>
+ * <li>GL_RENDERER: <i>Gallium 0.4 on SVGA3D; build: RELEASE;</i> </li>
+ * </ul></li>
+ * </ul>
+ * Quirk can also be enabled via property: <code>jogl.fbo.force.min</code>.
+ */
+ public static final int NoFullFBOSupport = 11;
+
/** Number of quirks known. */
- public static final int COUNT = 11;
+ public static final int COUNT = 12;
private static final String[] _names = new String[] { "NoDoubleBufferedPBuffer", "NoDoubleBufferedBitmap", "NoSetSwapInterval",
"NoOffscreenBitmap", "NoSetSwapIntervalPostRetarget", "GLSLBuggyDiscard",
"GLNonCompliant", "GLFlushBeforeRelease", "DontCloseX11Display",
- "NeedCurrCtx4ARBPixFmtQueries", "NeedCurrCtx4ARBCreateContext"
+ "NeedCurrCtx4ARBPixFmtQueries", "NeedCurrCtx4ARBCreateContext",
+ "NoFullFBOSupport"
};
private final int _bitmask;
@@ -183,6 +207,20 @@ public class GLRendererQuirks {
}
/**
+ * @param quirks a list of valid quirks
+ * @throws IllegalArgumentException if one of the quirks is out of range
+ */
+ public GLRendererQuirks(List<Integer> quirks) throws IllegalArgumentException {
+ int bitmask = 0;
+ for(int i=0; i<quirks.size(); i++) {
+ final int quirk = quirks.get(i);
+ validateQuirk(quirk);
+ bitmask |= 1 << quirk;
+ }
+ _bitmask = bitmask;
+ }
+
+ /**
* @param quirk the quirk to be tested
* @return true if quirk exist, otherwise false
* @throws IllegalArgumentException if quirk is out of range