Re: Problems reading the z-buffer

New Message Reply Date view Thread view Subject view Author view

Mario Veraart (rioj7++at++fel.tno.nl)
Fri, 27 Mar 1998 18:57:09 +0100 (MET)


Wilfried Zeise wrote:

>
> Hi pfAll:
>
> I am using Performer 2.2 on an Onyx i-station with IRIX 6.2. I want to
> read the z-buffer values for my currently displayed frame, and save them
> as an image file (ppm format), for image processing purposes. But I am
> having some troubles with it. To save such an image I modified the file
> perfly.C.
>
> [snap]
>
>
> glReadPixels(...,GL_RGBA,...) works fine.
>
> The GL_DEPTH tests show the following results:
>
> frame_snapshot: bias 0.000000, scale 1.000000, bits 23.000000, range
> (0.000000, 1.000000), depth testing enabled
>
> In my opinion, this means glReadPixels(...,GL_DEPTH_COMPONENT,...)
> should work. But I get for every pixel the value z=1.0 !!
>
>
> Any idea why glReadPixels(...,GL_DEPTH_COMPONENT,...) douesn't work in
> my application?

If you have antialiasing enabled then you might have problem reading
the Z-buffer, because then you have for every sub pixel a possible
Z-value.

Mario
=======================================================================
List Archives, FAQ, FTP: http://www.sgi.com/Technology/Performer/
            Submissions: info-performer++at++sgi.com
        Admin. requests: info-performer-request++at++sgi.com


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:57:06 PDT

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.