Hi Stefano,

On Mon, 30 Apr 2007, Stefano wrote:

> 2007/4/27, Stefano <[EMAIL PROTECTED]>:
>> for what I know, this could be simply done changing the
>> current GL_READ_BUFFER from the TextureGrabForeground draw() method...
>
> this is not true, as glReadBuffer() just specifies the current 
> framebuffer, not the buffer component.. isn't it? I've searched a lot 
> and i've found some extensions such as WGL_NV_render_depth_texture that 
> maybe could be useful for the purpose.. but I really don't know how. :p

I never tried it, but isn't the ARB_depth_texture extension exactly for
this purpose?

http://oss.sgi.com/projects/ogl-sample/registry/ARB/depth_texture.txt

If I understand the spec correctly (I just had a very quick look) after 
filling up your depthbuffer, you just copy the depthbuffer content to a 
texture via glTexImage2D() with the internalformat set to e.g. 
DEPTH_COMPONENT24_ARB and after that you can just bind this as a texture.

I don't know if this can be done easily with a TextureChunk though...

HTH,
        Akos

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to