From a303cd13ff62f94a0459978735620e37d72bbb77 Mon Sep 17 00:00:00 2001 From: Kenneth Russel Date: Sun, 19 Nov 2006 20:51:57 +0000 Subject: Fixed Issue 213: Expose GLCaps from GLDrawable Added getChosenGLCapabilities() to the GLDrawable interface. Implemented on Windows, Unix and Mac OS X platforms with various techniques. Attempts to provide correct answers in all cases, even when the GLCapabilitiesChooser mechanism is not supported. Required addition of new platform-specific Java code in most cases to either re-convert existing PIXELFORMATDESCRIPTORS / XVisualInfos, or to query the pixel format or visual chosen for drawables like pbuffers for which the chooser mechanism is not (yet) implemented. Tested on Windows, Solaris/x86, and Mac OS X with on-screen, off-screen and pbuffer drawables. (Full support for the Java2D/JOGL bridge is not yet in place; the answer returned from the GLJPanel in this case is currently the default GLCapabilities, and it is likely that "external" GLDrawables will return null.) git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@989 232f8b59-042b-4e1e-8c03-345bb8c30851 --- src/classes/com/sun/opengl/impl/windows/WindowsGLDrawableFactory.java | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/classes/com/sun/opengl/impl/windows/WindowsGLDrawableFactory.java') diff --git a/src/classes/com/sun/opengl/impl/windows/WindowsGLDrawableFactory.java b/src/classes/com/sun/opengl/impl/windows/WindowsGLDrawableFactory.java index 1c77d5b04..6e1b4ca99 100644 --- a/src/classes/com/sun/opengl/impl/windows/WindowsGLDrawableFactory.java +++ b/src/classes/com/sun/opengl/impl/windows/WindowsGLDrawableFactory.java @@ -118,6 +118,9 @@ public class WindowsGLDrawableFactory extends GLDrawableFactoryImpl { }; maybeDoSingleThreadedWorkaround(r); } + if (DEBUG) { + System.err.println("WindowsGLDrawableFactory.canCreateGLPbuffer() = " + canCreateGLPbuffer); + } return canCreateGLPbuffer; } -- cgit v1.2.3