D3D12_RENDER_TARGET_VIEW_DESC structure

Describes the subresources from a resource that are accessible by using a render-target view.

Syntax

typedef struct D3D12_RENDER_TARGET_VIEW_DESC {
  DXGI_FORMAT         Format;
  D3D12_RTV_DIMENSION ViewDimension;
  union {
    D3D12_BUFFER_RTV        Buffer;
    D3D12_TEX1D_RTV         Texture1D;
    D3D12_TEX1D_ARRAY_RTV   Texture1DArray;
    D3D12_TEX2D_RTV         Texture2D;
    D3D12_TEX2D_ARRAY_RTV   Texture2DArray;
    D3D12_TEX2DMS_RTV       Texture2DMS;
    D3D12_TEX2DMS_ARRAY_RTV Texture2DMSArray;
    D3D12_TEX3D_RTV         Texture3D;
  };
};

Members

Format

A DXGI_FORMAT-typed value that specifies the viewing format.

ViewDimension

A D3D12_RTV_DIMENSION-typed value that specifies how the render-target resource will be accessed. This type specifies how the resource will be accessed. This member also determines which _RTV to use in the following union.

__unnamed_union_0782_6

__unnamed_union_0782_6.Buffer

__unnamed_union_0782_6.Texture1D

__unnamed_union_0782_6.Texture1DArray

__unnamed_union_0782_6.Texture2D

__unnamed_union_0782_6.Texture2DArray

__unnamed_union_0782_6.Texture2DMS

__unnamed_union_0782_6.Texture2DMSArray

__unnamed_union_0782_6.Texture3D

Remarks

Pass a render-target-view description into ID3D12Device::CreateRenderTargetView to create a render-target view.

A render-target view can't use the following formats:

  • Any typeless format.
  • DXGI_FORMAT_R32G32B32 if the view will be used to bind a buffer (vertex, index, constant, or stream-output).
If the format is set to DXGI_FORMAT_UNKNOWN, then the format of the resource that the view binds to the pipeline will be used.

Requirements

   
Header d3d12.h

See Also

Core Structures