DD_DXAPI_OPENSURFACE control code

A video capture driver passes DD_DXAPI_OPENSURFACE in the dwFunctionNum parameter of the DxApi function to notify the kernel-mode video transport that the driver requires a surface object.

Input Parameters

  • lpvInBuffer
    Pointer to a DDOPENSURFACEIN structure that contains the DirectDrawSurface object information.

Output Parameters

  • lpvOutBuffer
    Pointer to a DDOPENSURFACEOUT structure that contains the new DirectDrawSurface handle information.

Remarks

The object is specified by the dwSurfaceHandle member of DDOPENSURFACEIN, which is the handle passed down from user mode. The hDirectDraw member of DDOPENSURFACEIN specifies the DirectDraw object with which the surface is associated. The driver must also specify a callback that is called when the surface becomes unusable due to it being released at user mode, a full-screen command prompt, or a mode change. The pContext member contains a value that is passed if the pfnSurfaceClose callback function is ever called.

If the ddRVal member of DDOPENSURFACEOUT is set to DD_OK, the output from this function identifier is a new surface handle. This new handle must be used on all subsequent calls that reference this surface.

This function identifier can only be called from PASSIVE_LEVEL.

Requirements

Header file: Ddkmapi.h (include Ddkmapi.h)

See also

DDOPENSURFACEIN

DDOPENSURFACEOUT

NotifyCallback