Sets all the elements in a render target to one value.
public:
void ClearRenderTargetViewX(
ID3D11RenderTargetView *pRenderTargetView,
UINT Flags,
const FLOAT ColorRGBA[4]
)
pRenderTargetView
Type: ID3D11RenderTargetView *
[in] The render target view, as a pointer to a ID3D11RenderTargetView.
Flags
Type: UINT
[in] Flags to control this method, as a bitwise-OR’d combination of D3D11X_CLEAR_COLOR_FLAG enumeration constants, such as D3D11X_CLEAR_COLOR_NO_COMPRESSION (which performs a slow clear of the target, and prevents applying color fragment and clear color indirection).
ColorRGBA
Type: FLOAT
[in] A 4-component array that represents the color to fill the render target with.
To clear a render target to a specific integer value bit pattern, render a screen-aligned quad instead of using this method. This method accepts a floating point value, which may not have the same bit pattern as the original integer.
The full extent of the resource view is always cleared. Viewport and scissor settings are not applied.
Header: Declared in d3d11_x.h.
Library: Use d3d11_x.lib.