ID3D12GraphicsCommandList::ClearUnorderedAccessViewUint method

Sets all the elements in a unordered-access view to the specified integer values.

Syntax


void ClearUnorderedAccessViewUint(
  [in]       D3D12_GPU_DESCRIPTOR_HANDLE ViewGPUHandleInCurrentHeap,
  [in]       D3D12_CPU_DESCRIPTOR_HANDLE ViewCPUHandle,
  [in]       ID3D12Resource              *pResource,
  [inconst UINT                        Values[4],
  [in]       UINT                        NumRects,
  [inconst D3D12_RECT                  *pRects
);

Parameters

ViewGPUHandleInCurrentHeap [in]

Type: D3D12_GPU_DESCRIPTOR_HANDLE

A D3D12_GPU_DESCRIPTOR_HANDLE structure that describes the GPU descriptor handle that represents the start of the heap for the unordered-access view to clear.

ViewCPUHandle [in]

Type: D3D12_CPU_DESCRIPTOR_HANDLE

A D3D12_CPU_DESCRIPTOR_HANDLE structure that describes the CPU descriptor handle that represents the start of the heap for the render target to clear.

pResource [in]

Type: ID3D12Resource*

A pointer to the ID3D12Resource interface that represents the unordered-access-view resource to clear.

Values [in]

Type: const UINT[4]

A 4-component array that containing the values to fill the unordered-access-view resource with.

NumRects [in]

Type: UINT

The number of rectangles in the array that the pRects parameter specifies.

pRects [in]

Type: const D3D12_RECT*

An array of D3D12_RECT structures for the rectangles in the resource view to clear. If NULL, ClearUnorderedAccessViewUint clears the entire resource view.

Return value

This method does not return a value.

Remarks

Runtime validation

Validation failure will result in the call to ID3D12GraphicsCommandList::Close returning E_INVALIDARG.

Debug layer

The debug layer will issue errors if the input values are outside of a normalized range.

The debug layer will issue an error if the subresources referenced by the view are not in the appropriate state. For ClearUnorderedAccessViewUint, the state must be D3D12_RESOURCE_STATE_UNORDERED_ACCESS.

Requirements

Header

D3d12.h

Library

D3d12.lib

DLL

D3d12.dll

See also

ID3D12GraphicsCommandList

 

 

Show: