Expand Minimize

VideoDecoderBeginFrame function

Starts a DirectX Video Acceleration (DXVA) decoding operation to decode a video frame.

Syntax


HRESULT APIENTRY* VideoDecoderBeginFrame(
  _In_  D3D10DDI_HDEVICE hDevice,
  _In_  D3D11_1DDI_HDECODE hDecoder,
  _In_  const D3D11_1DDIARG_VIDEODECODERBEGINFRAME *pBeginFrame
);

Parameters

hDevice [in]

A handle to the display device (graphics context).

hDecoder [in]

A handle to the video decoder object that was created through a call to the CreateVideoDecoder function.

pBeginFrame [in]

A pointer to a D3D11_1DDIARG_VIDEODECODERBEGINFRAME structure. For more information, see the Remarks section.

Return value

VideoDecoderBeginFrame returns one of the following values:

Return codeDescription
S_OK

The decoding operation was started successfully.

E_OUTOFMEMORY

Memory was not available to complete the operation.

 

Remarks

If the VideoDecoderBeginFrame returns S_OK, the Microsoft Direct3D runtime calls the VideoDecoderSubmitBuffers function to perform the decoding operations. When all decoding operations have been executed, the runtime calls the VideoDecoderEndFrame function to stop the decoding operation on a video frame.

Note  Each call to VideoDecoderBeginFrame must have a matching call to VideoDecoderEndFrame, and VideoDecoderBeginFrame calls cannot be nested.

The D3D11_1DDIARG_VIDEODECODERBEGINFRAME structure contains the following data:

  • The resource that will receive the decrypted and decoded data.

  • A content key that was used to encrypt the video frame data.

    If the pContentKey member of this structure is not set to NULL, the buffer that is referenced by this member contains a per-frame content key. This key must be used to decrypt the data instead of using the session key.

    Note  If the pContentKey member is not set to NULL, the buffer that is referenced by this member is encrypted by using the session key with the AES-ECB algorithm.

    If the pContentKey member is set to NULL, the video frame data should be decrypted by using the session key.

Requirements

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Header

D3d10umddi.h (include D3d10umddi.h)

See also

CreateVideoDecoder
VideoDecoderEndFrame
VideoDecoderSubmitBuffers

 

 

Send comments about this topic to Microsoft

Show:
© 2014 Microsoft