Posted by
markm on
Nov 23, 2010; 8:57pm
URL: https://forum.jogamp.org/Depth-buffer-not-working-on-Win7-64b-tp1737435p1956359.html
Right, specific information for my system: Using JOGL 2.0-b222-20101118 on Windows XP Home with an Intel 915GM graphics chip.
The datasheet for the 915GM (
http://www.intel.com/Products/Notebook/Chipsets/915GM/915GM-technicaldocuments.htm) says
"A 16-bit Z/W or 24 bit Z/W buffer can be selected with a 16-bit color buffer. Z buffer is not supported in 8-bit mode."
Which seems consistent with others' suggestions that it's my graphics chip/driver(?) at fault for failing to honour a 24-bit request.
JOGLGearsDemo.java (modified so it explicitly asks for the default GLProfile and prints depth buffer info as above) gives the following output for the default 24-bit case:
Requesting 24-bit depth buffer.
Actual depth buffer: 0
INIT GL IS: javax.media.opengl.DebugGL2
Chosen GLCapabilities: GLCapabilities[Capabilities[Onscreen: true, Red: 8, Green: 8, Blue: 8, Alpha: 0, Opaque: true], GL profile: GLProfile[GL2/GL2], PBuffer: false, DoubleBuffered: true, Stereo: false, HardwareAccelerated: true, DepthBits: 24, StencilBits: 0, Red Accum: 0, Green Accum: 0, Blue Accum: 0, Alpha Accum: 0, Multisample: false, Num samples: 0, PBuffer-FloatingPointBuffers: false, PBuffer-RenderToTexture: false, PBuffer-RenderToTextureRectangle: false]
GL_VENDOR: Intel
GL_RENDERER: Intel 915GM
GL_VERSION: 1.4.0 - Build 4.14.10.4020
JOGLGearsDemo.dispose: AWT-GLCanvas[ class javax.media.nativewindow.awt.AWTGraphicsConfiguration[class javax.media.nativewindow.awt.AWTGraphicsScreen[class javax.media.nativewindow.awt.AWTGraphicsDevice[type AWT[subType null], connection \Display0, unitID 0, awtDevice Win32GraphicsDevice[screen=0], handle 0x0], idx 0],
chosen GLCapabilities[Capabilities[Onscreen: true, Red: 8, Green: 8, Blue: 8, Alpha: 0, Opaque: true], GL profile: GLProfile[GL2/GL2], PBuffer: false, DoubleBuffered: true, Stereo: false, HardwareAccelerated: true, DepthBits: 24, StencilBits: 0, Red Accum: 0, Green Accum: 0, Blue Accum: 0, Alpha Accum: 0, Multisample: false, Num samples: 0, PBuffer-FloatingPointBuffers: false, PBuffer-RenderToTexture: false, PBuffer-RenderToTextureRectangle: false],
requested GLCapabilities[Capabilities[Onscreen: true, Red: 8, Green: 8, Blue: 8, Alpha: 0, Opaque: true], GL profile: GLProfile[GL2/GL2], PBuffer: false, DoubleBuffered: true, Stereo: false, HardwareAccelerated: true, DepthBits: 24, StencilBits: 0, Red Accum: 0, Green Accum: 0, Blue Accum: 0, Alpha Accum: 0, Multisample: false, Num samples: 0, PBuffer-FloatingPointBuffers: false, PBuffer-RenderToTexture: false, PBuffer-RenderToTextureRectangle: false],
sun.awt.Win32GraphicsConfig@83cc67[dev=Win32GraphicsDevice[screen=0],pixfmt=0],
encapsulated WindowsWGLGraphicsConfiguration[class javax.media.nativewindow.DefaultGraphicsScreen[class javax.media.nativewindow.windows.WindowsGraphicsDevice[type Windows, connection decon, unitID 0, handle 0x0], idx 0], pfdID 1, wglChoosen true,
requested GLCapabilities[Capabilities[Onscreen: true, Red: 8, Green: 8, Blue: 8, Alpha: 0, Opaque: true], GL profile: GLProfile[GL2/GL2], PBuffer: false, DoubleBuffered: true, Stereo: false, HardwareAccelerated: true, DepthBits: 24, StencilBits: 0, Red Accum: 0, Green Accum: 0, Blue Accum: 0, Alpha Accum: 0, Multisample: false, Num samples: 0, PBuffer-FloatingPointBuffers: false, PBuffer-RenderToTexture: false, PBuffer-RenderToTextureRectangle: false],
chosen GLCapabilities[Capabilities[Onscreen: true, Red: 8, Green: 8, Blue: 8, Alpha: 8, Opaque: true], GL profile: GLProfile[GL2/GL2], PBuffer: false, DoubleBuffered: false, Stereo: false, HardwareAccelerated: true, DepthBits: 0, StencilBits: 0, Red Accum: 0, Green Accum: 0, Blue Accum: 0, Alpha Accum: 0, Multisample: false, Num samples: 0, PBuffer-FloatingPointBuffers: true, PBuffer-RenderToTexture: false, PBuffer-RenderToTextureRectangle: false]]], com.jogamp.opengl.impl.windows.wgl.WindowsOnscreenWGLDrawable]
...and in the 16-bit case:
Requesting 16-bit depth buffer.
Actual depth buffer: 16
INIT GL IS: javax.media.opengl.DebugGL2
Chosen GLCapabilities: GLCapabilities[Capabilities[Onscreen: true, Red: 8, Green: 8, Blue: 8, Alpha: 0, Opaque: true], GL profile: GLProfile[GL2/GL2], PBuffer: false, DoubleBuffered: true, Stereo: false, HardwareAccelerated: true, DepthBits: 16, StencilBits: 0, Red Accum: 0, Green Accum: 0, Blue Accum: 0, Alpha Accum: 0, Multisample: false, Num samples: 0, PBuffer-FloatingPointBuffers: false, PBuffer-RenderToTexture: false, PBuffer-RenderToTextureRectangle: false]
GL_VENDOR: Intel
GL_RENDERER: Intel 915GM
GL_VERSION: 1.4.0 - Build 4.14.10.4020
JOGLGearsDemo.dispose: AWT-GLCanvas[ class javax.media.nativewindow.awt.AWTGraphicsConfiguration[class javax.media.nativewindow.awt.AWTGraphicsScreen[class javax.media.nativewindow.awt.AWTGraphicsDevice[type AWT[subType null], connection \Display0, unitID 0, awtDevice Win32GraphicsDevice[screen=0], handle 0x0], idx 0],
chosen GLCapabilities[Capabilities[Onscreen: true, Red: 8, Green: 8, Blue: 8, Alpha: 0, Opaque: true], GL profile: GLProfile[GL2/GL2], PBuffer: false, DoubleBuffered: true, Stereo: false, HardwareAccelerated: true, DepthBits: 16, StencilBits: 0, Red Accum: 0, Green Accum: 0, Blue Accum: 0, Alpha Accum: 0, Multisample: false, Num samples: 0, PBuffer-FloatingPointBuffers: false, PBuffer-RenderToTexture: false, PBuffer-RenderToTextureRectangle: false],
requested GLCapabilities[Capabilities[Onscreen: true, Red: 8, Green: 8, Blue: 8, Alpha: 0, Opaque: true], GL profile: GLProfile[GL2/GL2], PBuffer: false, DoubleBuffered: true, Stereo: false, HardwareAccelerated: true, DepthBits: 16, StencilBits: 0, Red Accum: 0, Green Accum: 0, Blue Accum: 0, Alpha Accum: 0, Multisample: false, Num samples: 0, PBuffer-FloatingPointBuffers: false, PBuffer-RenderToTexture: false, PBuffer-RenderToTextureRectangle: false],
sun.awt.Win32GraphicsConfig@83cc67[dev=Win32GraphicsDevice[screen=0],pixfmt=0],
encapsulated WindowsWGLGraphicsConfiguration[class javax.media.nativewindow.DefaultGraphicsScreen[class javax.media.nativewindow.windows.WindowsGraphicsDevice[type Windows, connection decon, unitID 0, handle 0x0], idx 0], pfdID 4, wglChoosen true,
requested GLCapabilities[Capabilities[Onscreen: true, Red: 8, Green: 8, Blue: 8, Alpha: 0, Opaque: true], GL profile: GLProfile[GL2/GL2], PBuffer: false, DoubleBuffered: true, Stereo: false, HardwareAccelerated: true, DepthBits: 16, StencilBits: 0, Red Accum: 0, Green Accum: 0, Blue Accum: 0, Alpha Accum: 0, Multisample: false, Num samples: 0, PBuffer-FloatingPointBuffers: false, PBuffer-RenderToTexture: false, PBuffer-RenderToTextureRectangle: false],
chosen GLCapabilities[Capabilities[Onscreen: true, Red: 8, Green: 8, Blue: 8, Alpha: 8, Opaque: true], GL profile: GLProfile[GL2/GL2], PBuffer: false, DoubleBuffered: true, Stereo: false, HardwareAccelerated: true, DepthBits: 16, StencilBits: 0, Red Accum: 16, Green Accum: 16, Blue Accum: 16, Alpha Accum: 16, Multisample: false, Num samples: 0, PBuffer-FloatingPointBuffers: true, PBuffer-RenderToTexture: false, PBuffer-RenderToTextureRectangle: false]]], com.jogamp.opengl.impl.windows.wgl.WindowsOnscreenWGLDrawable]