aboutsummaryrefslogtreecommitdiffstats
path: root/src/jogl/classes
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2015-07-24 02:12:06 +0200
committerSven Gothel <[email protected]>2015-07-24 02:12:06 +0200
commitf60a737b18d6763ac1f443fce0b61c844666e2a8 (patch)
treea857fe7ab52760095e6e1ab28ff8bb9efc503e38 /src/jogl/classes
parent5d58f63300771843687db18ad4da67c5882fd52e (diff)
Bug 1146, Bug 1158: Add unit test for GLContext creation after showing tool-tip within JDialog
Test passes on GNU/Linux X11 and Windows - both using NVidia driver. Unit test is based on Robin Provost's code as attached in Bug 1158.
Diffstat (limited to 'src/jogl/classes')
-rw-r--r--src/jogl/classes/com/jogamp/opengl/JoglVersion.java17
1 files changed, 13 insertions, 4 deletions
diff --git a/src/jogl/classes/com/jogamp/opengl/JoglVersion.java b/src/jogl/classes/com/jogamp/opengl/JoglVersion.java
index af16348a8..7589b3776 100644
--- a/src/jogl/classes/com/jogamp/opengl/JoglVersion.java
+++ b/src/jogl/classes/com/jogamp/opengl/JoglVersion.java
@@ -129,7 +129,14 @@ public class JoglVersion extends JogampVersion {
public static StringBuilder getGLInfo(final GL gl, final StringBuilder sb) {
return getGLInfo(gl, sb, false);
}
- public static StringBuilder getGLInfo(final GL gl, StringBuilder sb, final boolean withCapabilitiesAndExtensionInfo) {
+ public static StringBuilder getGLInfo(final GL gl, final StringBuilder sb, final boolean withCapabilitiesAndExtensionInfo) {
+ return getGLInfo(gl, sb, true, withCapabilitiesAndExtensionInfo, withCapabilitiesAndExtensionInfo);
+ }
+
+ public static StringBuilder getGLInfo(final GL gl, StringBuilder sb,
+ final boolean withAvailabilityInfo,
+ final boolean withCapabilitiesInfo,
+ final boolean withExtensionInfo) {
final AbstractGraphicsDevice device = gl.getContext().getGLDrawable().getNativeSurface()
.getGraphicsConfiguration().getScreen().getDevice();
if(null==sb) {
@@ -139,12 +146,14 @@ public class JoglVersion extends JogampVersion {
sb.append(VersionUtil.SEPERATOR).append(Platform.getNewline());
sb.append(device.getClass().getSimpleName()).append("[type ")
.append(device.getType()).append(", connection ").append(device.getConnection()).append("]: ").append(Platform.getNewline());
- GLProfile.glAvailabilityToString(device, sb, "\t", 1);
+ if( withAvailabilityInfo ) {
+ GLProfile.glAvailabilityToString(device, sb, "\t", 1);
+ }
sb.append(Platform.getNewline());
- sb = getGLStrings(gl, sb, withCapabilitiesAndExtensionInfo);
+ sb = getGLStrings(gl, sb, withExtensionInfo);
- if( withCapabilitiesAndExtensionInfo ) {
+ if( withCapabilitiesInfo ) {
sb = getAllAvailableCapabilitiesInfo(device, sb);
}
return sb;