PDXVAHDSW_Plugin callback function (dxvahd.h)

Pointer to a function that initializes a software plug-in device for Microsoft DirectX Video Acceleration High Definition (DXVA-HD).

Syntax

PDXVAHDSW_Plugin PdxvahdswPlugin;

HRESULT PdxvahdswPlugin(
  [in]  UINT Size,
  [out] void *pCallbacks
)
{...}

Parameters

[in] Size

The size of the structure pointed to by the pCallbacks parameter, in bytes.

[out] pCallbacks

A pointer to an uninitialized DXVAHDSW_CALLBACKS structure. The function fills this structure with pointers to the plug-in device's callback functions.

Return value

If this callback function succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

The DXVAHDSW_CALLBACKS structure contains pointers to callback functions. The software plug-in device must implement these callback functions. The DXVA-HD device calls the PDXVAHDSW_Plugin function to get the callback function pointers from the plug-in device.

Examples

HRESULT CALLBACK DXVAHDSW_Plugin(UINT Size, void* pv)
{
    if (Size < sizeof(DXVAHDSW_CALLBACKS))
    {
        return E_INVALIDARG;
    }

    DXVAHDSW_CALLBACKS* pCallbacks = (DXVAHDSW_CALLBACKS*) pv;

    // TODO: Fill in pCallbacks structure.

    return S_OK;
}

Requirements

Requirement Value
Minimum supported client Windows 7 [desktop apps only]
Minimum supported server Windows Server 2008 R2 [desktop apps only]
Target Platform Windows
Header dxvahd.h

See also

DXVA-HD

DXVAHD_CreateDevice

Media Foundation Functions