IDXVAHD_Device::CreateVideoSurface method (dxvahd.h)

Creates one or more Microsoft Direct3D video surfaces.

Syntax

HRESULT CreateVideoSurface(
  UINT                Width,
  UINT                Height,
  D3DFORMAT           Format,
  D3DPOOL             Pool,
  DWORD               Usage,
  DXVAHD_SURFACE_TYPE Type,
  UINT                NumSurfaces,
  IDirect3DSurface9   **ppSurfaces,
  HANDLE              *pSharedHandle
);

Parameters

Width

The width of each surface, in pixels.

Height

The height of each surface, in pixels.

Format

The pixel format, specified as a D3DFORMAT value or FOURCC code. For more information, see Video FOURCCs.

Pool

The memory pool in which the surface is created. This parameter must equal the InputPool member of the DXVAHD_VPDEVCAPS structure. Call the IDXVAHD_Device::GetVideoProcessorDeviceCaps method to get this value.

Usage

Reserved. Set to 0.

Type

The type of surface to create, specified as a member of the DXVAHD_SURFACE_TYPE enumeration.

NumSurfaces

The number of surfaces to create.

ppSurfaces

A pointer to an array of IDirect3DSurface9 pointers. The NumSurfaces parameter specifies the number of elements in the array. The method fills the array with pointers to the new video surfaces. The caller must release the pointers.

pSharedHandle

Reserved. Set to NULL.

Return value

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

Requirements

   
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

IDXVAHD_Device