View Full Version : Direct transfer Depth Buffer to texture
pkuloop
09-21-2003, 09:06 AM
Is there any quick method direct transfer Depth information into on texture without read back to main memory?
glCopyTexSubImage2D() with an internal format of GL_DEPTH_COMPONENT
pkuloop
09-23-2003, 01:36 PM
I try to use pbufer and directly bind the pbuffer to a texture.
For RGB it works.
wglBindTexImageARB( pbuffer.hpbuffer, WGL_FRONT_LEFT_ARB )
however, when I use WGL_DEPTH_COMPONENT_NV
it fails.
pkuloop
09-23-2003, 05:06 PM
Now I get it right
add WGL_BIND_TO_TEXTURE_DEPTH_NV, TRUE,
for the pixel format
and WGL_DEPTH_TEXTURE_FORMAT_NV, WGL_TEXTURE_DEPTH_COMPONENT_NV,
for the pbuffer attib
eyebex
10-10-2003, 11:11 AM
what's the best way to do this on ati boards? use gl_arb_depth_texture somehow?
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.