Clearing Depth Buffers
Microsoft DirectX 9.0 SDK Update (October 2004)

Clearing Depth Buffers


Many C++ applications clear the depth buffer before rendering each new frame. You can explicitly clear the depth buffer through Microsoft Direct3D by calling IDirect3DDevice9::Clear and specifying D3DCLEAR_ZBUFFER for the Flags parameter. The IDirect3DDevice9::Clear method allows you to specify an arbitrary depth value in the Z parameter.



© 2004 Microsoft Corporation. All rights reserved.
Feedback? Please provide us with your comments on this topic.
For more help, visit the DirectX Developer Center.