CD3D11_DEPTH_STENCIL_DESC class
Represents a depth-stencil-state structure and provides convenience methods for creating depth-stencil-state structures.
Members
The CD3D11_DEPTH_STENCIL_DESC class inherits from D3D11_DEPTH_STENCIL_DESC. CD3D11_DEPTH_STENCIL_DESC also has these types of members:
- Constructors
- Methods
Constructors
The CD3D11_DEPTH_STENCIL_DESC class has these constructors.
Constructor | Description |
---|---|
CD3D11_DEPTH_STENCIL_DESC() | Instantiates a new instance of an uninitialized CD3D11_DEPTH_STENCIL_DESC structure. |
CD3D11_DEPTH_STENCIL_DESC(CD3D11_DEFAULT)(CD3D11_DEFAULT) | Instantiates a new instance of a CD3D11_DEPTH_STENCIL_DESC structure that is initialized with default depth-stencil-state values. |
CD3D11_DEPTH_STENCIL_DESC(D3D11_DEPTH_STENCIL_DESC_values)(BOOL,D3D11_DEPTH_WRITE_MASK,D3D11_COMPARISON_FUNC,BOOL,UINT8,UINT8,D3D11_STENCIL_OP,D3D11_STENCIL_OP,D3D11_STENCIL_OP,D3D11_COMPARISON_FUNC,D3D11_STENCIL_OP,D3D11_STENCIL_OP,D3D11_STENCIL_OP,D3D11_COMPARISON_FUNC) | Instantiates a new instance of a CD3D11_DEPTH_STENCIL_DESC structure that is initialized with D3D11_DEPTH_STENCIL_DESC values. |
Methods
The CD3D11_DEPTH_STENCIL_DESC class has these methods.
Method | Description |
---|---|
~CD3D11_DEPTH_STENCIL_DESC | Destroys an instance of a CD3D11_DEPTH_STENCIL_DESC structure. |
CD3D11_DEPTH_STENCIL_DESC(D3D11_DEPTH_STENCIL_DESC&)(const &D3D11_DEPTH_STENCIL_DESC) | Instantiates a new instance of a CD3D11_DEPTH_STENCIL_DESC structure that is initialized with a D3D11_DEPTH_STENCIL_DESC structure. |
D3D11_DEPTH_STENCIL_DESC() | This operator returns the address of a D3D11_DEPTH_STENCIL_DESC structure that contains the data from the CD3D11_DEPTH_STENCIL_DESC instance. |
Remarks
Here is how D3D11.h defines CD3D11_DEPTH_STENCIL_DESC:
struct CD3D11_DEPTH_STENCIL_DESC : public D3D11_DEPTH_STENCIL_DESC
{
CD3D11_DEPTH_STENCIL_DESC()
{}
explicit CD3D11_DEPTH_STENCIL_DESC( const D3D11_DEPTH_STENCIL_DESC& o ) :
D3D11_DEPTH_STENCIL_DESC( o )
{}
explicit CD3D11_DEPTH_STENCIL_DESC( CD3D11_DEFAULT )
{
DepthEnable = TRUE;
DepthWriteMask = D3D11_DEPTH_WRITE_MASK_ALL;
DepthFunc = D3D11_COMPARISON_LESS;
StencilEnable = FALSE;
StencilReadMask = D3D11_DEFAULT_STENCIL_READ_MASK;
StencilWriteMask = D3D11_DEFAULT_STENCIL_WRITE_MASK;
const D3D11_DEPTH_STENCILOP_DESC defaultStencilOp =
{ D3D11_STENCIL_OP_KEEP, D3D11_STENCIL_OP_KEEP, D3D11_STENCIL_OP_KEEP, D3D11_COMPARISON_ALWAYS };
FrontFace = defaultStencilOp;
BackFace = defaultStencilOp;
}
explicit CD3D11_DEPTH_STENCIL_DESC(
BOOL depthEnable,
D3D11_DEPTH_WRITE_MASK depthWriteMask,
D3D11_COMPARISON_FUNC depthFunc,
BOOL stencilEnable,
UINT8 stencilReadMask,
UINT8 stencilWriteMask,
D3D11_STENCIL_OP frontStencilFailOp,
D3D11_STENCIL_OP frontStencilDepthFailOp,
D3D11_STENCIL_OP frontStencilPassOp,
D3D11_COMPARISON_FUNC frontStencilFunc,
D3D11_STENCIL_OP backStencilFailOp,
D3D11_STENCIL_OP backStencilDepthFailOp,
D3D11_STENCIL_OP backStencilPassOp,
D3D11_COMPARISON_FUNC backStencilFunc )
{
DepthEnable = depthEnable;
DepthWriteMask = depthWriteMask;
DepthFunc = depthFunc;
StencilEnable = stencilEnable;
StencilReadMask = stencilReadMask;
StencilWriteMask = stencilWriteMask;
FrontFace.StencilFailOp = frontStencilFailOp;
FrontFace.StencilDepthFailOp = frontStencilDepthFailOp;
FrontFace.StencilPassOp = frontStencilPassOp;
FrontFace.StencilFunc = frontStencilFunc;
BackFace.StencilFailOp = backStencilFailOp;
BackFace.StencilDepthFailOp = backStencilDepthFailOp;
BackFace.StencilPassOp = backStencilPassOp;
BackFace.StencilFunc = backStencilFunc;
}
~CD3D11_DEPTH_STENCIL_DESC() {}
operator const D3D11_DEPTH_STENCIL_DESC&() const { return *this; }
};
Requirements
Minimum supported client |
Windows 7 [desktop apps | UWP apps] |
Minimum supported server |
Windows Server 2008 R2 [desktop apps | UWP apps] |
Header |
D3D11.h |
Library |
D3D11.lib |