Microsoft.DirectX.Direct3D.ClearFlags. Flags that indicate which surfaces to clear. This parameter can be any combination of the following flags, but at least one flag must be used. ClearFlags.Stencil: Clears the stencil buffer to the value in the stencil parameter.ClearFlags.Target: Clears the render target to the color in the color parameter.ClearFlags.ZBuffer: Clears the depth buffer to the value in the Z parameter.
color
System.Drawing.Color. A Color object that represents the color to which the render target surface is cleared.
zdepth
System.Single. New z value that this method stores in the depth buffer. This parameter can be in the range of 0.0 through 1.0 (for z-based or w-based depth buffers). A value of 0.0 represents the nearest distance to the viewer; a value of 1.0 represents the farthest distance.
stencil
System.Int32. Integer value to store in each stencil-buffer entry. This parameter can be in the range of 0 through 2n-1, where n is the bit depth of the stencil buffer.
Remarks
This method fails if the ZBuffer or Stencil flags are specified when the render target does not have an attached depth buffer. Similarly, the method fails if the Stencil flag is specified when the depth-buffer format does not contain stencil buffer information.