Graphics Reference
In-Depth Information
Struct D3D11_TEX2D_DSV {
UINT MipSlice;
}
Struct D3D11_TEX2D_ARRAY_DSV {
UINT MipSlice;
UINT FirstArraySlice;
UINT ArraySize;
}
Struct D3D11_TEX2DMS_DSV {
UINT UnusedField_NothingToDefine;
}
struct D3D11_TEX2DMS_ARRAY_DSV {
UINT FirstArraySlice;
UINT ArraySize;
}
Listing 2.40. The various depth stencil view subresource selection structures.
HLSL objects. As we have seen in the 1D texture resource case, it is possible to interact
with texture resources in HLSL by declaring an appropriate resource object. This resource
object must then be matched with either a shader resource view or an unordered access
view with an appropriate resource attached to it. When a shader resource view is used,
the resource object allows only read access to the resource contents. This is reflected in
the types of resource objects that can be declared for use with shader resource views. The
read-only resource types are listed below.
Texture2D
Texture2DArray
Texture2DMS
Texture2DMSArray
TextureCube
TextureCubeArray
Of course, each of these resources specifies a particular type of shader resource view
that it can be bound to. For example, the Texture2DMS HLSL resource object must be
bound to a shader resource view that is connected to a multisampled 2D texture resource.
The unordered access view provides read and write access to the attached resource, but it
can only be used with a subset of the resource objects shown above for the shader resource
views. The available resource objects are shown below.
Search WWH ::




Custom Search