PDA

View Full Version : ATI GL_DEPTH_COMPONENT bug



ToolTech
10-18-2004, 12:59 PM
I am getting undefined values on some ATI hw with later drivers installed when reding depth buffer with GL_DEPTH_COMPONENT/GL_FLOAT from pbuffer. Can anybody confirm that non written fragments get undefined z values even if z buffer is cleared before rendering ? Is this a correct behaviour ?

ToolTech
10-19-2004, 02:35 AM
The same program on NVidia HW gives defined depth values even if fragemnt is not written.

Fragments clear with glClear is not updated on ATI hw ??

ToolTech
10-20-2004, 12:47 PM
I am amazed that nobody answers ?

maybe I am to vague in my description.. lets try again with more details...

I render to a pbuffer.

1. First I clear the depth to 1.0
2. I render a model with z updates enabled
3. I read the pbuffer with readpixel with GL_DEPTH_COMPONENT and GL_FLOAT size

On ATI latest drivers i get undefined (random) z values where no fragment have been updated that is not 1.0 even if i cleared the entire z buffer with glClear

On NVidia drivers I get defined 1.0

It seemes as ATI hw doesn't clear the actual fragments to 1.0 even if I do the glClear. I only get correct z values from fragments that have actually been rendered.

Now i wonder what is correct. I suppose a lot of people uses the depth values for shadow mapping ? What is the correct behaviour ? Should I expect defined z values or not ?

My guess is that it is an ATI driver bug !

knackered
10-20-2004, 01:44 PM
Of course you should get defined depth values. That's what glClear does.
I don't understand why your confused, you're dealing with ATI, the only people who put a tip-of-the-day on their blue screens.
Report this driver bug to the ATI developer relations, or whatever.