From 6b0a0906617ddc5ccbbfe5b1eafb03be2e730a3d Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Thu, 6 Aug 2009 00:46:30 -0700 Subject: Fix Offscreen/PBuffer [WGL/GLX]: No XVisual/PFD necessary here .. --- .../sun/opengl/impl/windows/wgl/WindowsPbufferWGLDrawable.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'src/jogl/classes/com/sun/opengl/impl/windows') diff --git a/src/jogl/classes/com/sun/opengl/impl/windows/wgl/WindowsPbufferWGLDrawable.java b/src/jogl/classes/com/sun/opengl/impl/windows/wgl/WindowsPbufferWGLDrawable.java index 79dda9049..20a891414 100644 --- a/src/jogl/classes/com/sun/opengl/impl/windows/wgl/WindowsPbufferWGLDrawable.java +++ b/src/jogl/classes/com/sun/opengl/impl/windows/wgl/WindowsPbufferWGLDrawable.java @@ -290,10 +290,12 @@ public class WindowsPbufferWGLDrawable extends WindowsWGLDrawable { GLCapabilities newCaps = WindowsWGLGraphicsConfiguration.AttribList2GLCapabilities(glProfile, iattributes, niattribs, ivalues, true, false, true); PIXELFORMATDESCRIPTOR pfd = WindowsWGLGraphicsConfiguration.createPixelFormatDescriptor(); if (WGL.DescribePixelFormat(parentHdc, pformats[whichFormat], pfd.size(), pfd) == 0) { - throw new GLException("Unable to describe pixel format " + pformats[whichFormat]); + if (DEBUG) { + System.err.println("Unable to describe pixel format (Continue: true) " + whichFormat + "/" + nformats + " pfdID " + pformats[whichFormat]+":\n\t"+newCaps); + } } if(newCaps.isOnscreen()) { - throw new GLException("Error: Selected Onscreen Caps for PBuffer: "+newCaps); + throw new GLException("Error: Selected Onscreen Caps for PBuffer: "+newCaps+"\n\t"+newCaps); } config.setCapsPFD(newCaps, pfd, pformats[whichFormat], true); } else { @@ -303,7 +305,7 @@ public class WindowsPbufferWGLDrawable extends WindowsWGLDrawable { } GLCapabilities newCaps = WindowsWGLGraphicsConfiguration.PFD2GLCapabilities(glProfile, pfd, false, true); if(newCaps.isOnscreen()) { - throw new GLException("Error: Selected Onscreen Caps for PBuffer: "+newCaps); + throw new GLException("Error: Selected Onscreen Caps for PBuffer: "+newCaps+"\n\t"+newCaps); } config.setCapsPFD(newCaps, pfd, pformats[whichFormat], false); } -- cgit v1.2.3