PFND3DDDI_SETDECODERENDERTARGET callback function (d3dumddi.h)

The SetDecodeRenderTarget function sets the render target surface for decoding operations.

Syntax

PFND3DDDI_SETDECODERENDERTARGET Pfnd3dddiSetdecoderendertarget;

HRESULT Pfnd3dddiSetdecoderendertarget(
  HANDLE hDevice,
  const D3DDDIARG_SETDECODERENDERTARGET *unnamedParam2
)
{...}

Parameters

hDevice

A handle to the display device (graphics context).

unnamedParam2

pData [in]

A pointer to a D3DDDIARG_SETDECODERENDERTARGET structure that describes the decode render target surface.

Return value

SetDecodeRenderTarget returns one of the following values:

Return code Description
S_OK The render target surface is successfully set.
E_OUTOFMEMORY SetDecodeRenderTarget could not allocate the required memory for it to complete.

Remarks

The SetDecodeRenderTarget function can be called only outside of a DecodeBeginFrame/DecodeEndFrame block.

Decode render targets are always created atomically through calls to the CreateResource function, where all of the decode buffers are indexes within a single resource. All decode render targets are created by setting the D3DDDI_RESOURCEFLAGS.DecodeRenderTarget bit-field flag in the Flags member of the D3DDDIARG_CREATERESOURCE structure.

Requirements

Requirement Value
Minimum supported client Available in Windows Vista and later versions of the Windows operating systems.
Target Platform Desktop
Header d3dumddi.h (include D3dumddi.h)

See also

CreateResource

D3DDDIARG_CREATERESOURCE

D3DDDIARG_SETDECODERENDERTARGET

D3DDDI_DEVICEFUNCS

D3DDDI_RESOURCEFLAGS

DecodeBeginFrame

DecodeEndFrame