ID3D12CommandQueueDownlevel::Present method

Copies contents from a Direct3D 12 Texture2D resource into a window.

Syntax

HRESULT Present
    ID3D12GraphicsCommandList *pOpenCommandList,
    ID3D12Resource *pSourceTex2D,
    HWND hWindow,
    D3D12_DOWNLEVEL_PRESENT_FLAGS Flags
);

Parameters

pOpenCommandList

Type: ID3D12GraphicsCommandList*

An open command list, which Direct3D 12 enqueues a Present command onto, and then closes and submits for you.

pSourceTex2D

Type: ID3D12Resource*

A resource containing your desired contents to display, with dimension D3D12_RESOURCE_DIMENSION_TEXTURE2D, and a format that is one of the following.

  • DXGI_FORMAT_R16G16B16A16_FLOAT
  • DXGI_FORMAT_R10G10B10A2_UNORM
  • DXGI_FORMAT_R8G8B8A8_UNORM
  • DXGI_FORMAT_R8G8B8A8_UNORM_SRGB
  • DXGI_FORMAT_B8G8R8X8_UNORM
  • DXGI_FORMAT_R10G10B10_XR_BIAS_A2_UNORM
  • DXGI_FORMAT_B8G8R8A8_UNORM
  • DXGI_FORMAT_B8G8R8A8_UNORM_SRGB

hWindow

Type: HWND

The handle to the window where the contents should be displayed.

Flags

Type: D3D12_DOWNLEVEL_PRESENT_FLAGS

Flags to modify the Present operation.

Return value

Returns S_OK on success, or else a failing HRESULT.

Requirements

Requirement Value
Header d3d12downlevel.h
DLL D3D12.dll (Windows 7 only)

See also