Bagikan melalui


DepthFormat Enumeration

Defines the format of data in a depth buffer.

Namespace: Microsoft.Xna.Framework.Graphics
Assembly: Microsoft.Xna.Framework (in microsoft.xna.framework.dll)

Syntax

public enum DepthFormat

Members

  Member name Description
Depth15Stencil1 A 16-bit depth-buffer bit depth in which 15 bits are reserved for the depth channel and 1 bit is reserved for the stencil channel.
Depth16 A 16-bit depth-buffer bit depth.
Depth24 A 32-bit depth-buffer bit depth that uses 24 bits for the depth channel.
Depth24Stencil4 A 32-bit depth-buffer bit depth that uses 24 bits for the depth channel and 4 bits for the stencil channel.
Depth24Stencil8 A nonlockable format that contains 24 bits of depth (in a 24-bit floating-point format − 20E4) and 8 bits of stencil.
Depth24Stencil8Single A 32-bit depth-buffer bit depth that uses 24 bits for the depth channel and 8 bits for the stencil channel.
Depth32 a 32-bit depth-buffer bit depth.
Unknown Format is unknown.

Remarks

All depth-stencil formats except Depth16Lockable indicate no particular bit ordering per pixel, and the driver is allowed to consume more than the indicated number of bits per depth channel (but not stencil channel).

See Also

Reference

CheckDepthStencilMatch
CheckDeviceFormat
AutoDepthStencilFormat
PresentOptions
Microsoft.Xna.Framework.Graphics Namespace

Platforms

Xbox 360, Windows XP SP2, Windows Vista