DrvGetDirectDrawInfo function (winddi.h)

The DrvGetDirectDrawInfo function returns the capabilities of the graphics hardware.

Syntax

BOOL DrvGetDirectDrawInfo(
  DHPDEV      dhpdev,
  DD_HALINFO  *pHalInfo,
  DWORD       *pdwNumHeaps,
  VIDEOMEMORY *pvmList,
  DWORD       *pdwNumFourCCCodes,
  DWORD       *pdwFourCC
);

Parameters

dhpdev

Handle to the PDEV returned by the driver's DrvEnablePDEV routine.

pHalInfo

Points to a DD_HALINFO structure in which the driver should return the hardware capabilities that it supports.

pdwNumHeaps

Points to the location in which the driver should return the number of VIDEOMEMORY structures pointed to by pvmList.

pvmList

Points to an array of VIDEOMEMORY structures in which the driver should return information about each display memory chunk that it controls. The driver should ignore this parameter when it is NULL.

pdwNumFourCCCodes

Points to the location in which the driver should return the number of DWORDs pointed to by pdwFourCC.

pdwFourCC

Points to an array of DWORDs in which the driver should return information about each FOURCC that it supports. The driver should ignore this parameter when it is NULL.

Return value

DrvGetDirectDrawInfo returns TRUE if it succeeds; otherwise, it returns FALSE.

Remarks

The driver's DrvGetDirectDrawInfo routine should do the following:

  • When pvmList and pdwFourCC are NULL:
    1. Reserve offscreen display memory for DirectDraw use.
    2. Write the number of driver display memory heaps and supported FOURCCs in pdwNumHeaps and pdwNumFourCC, respectively.
  • When pvmList and pdwFourCC are not NULL:
    1. Write the number of driver display memory heaps and supported FOURCCs in pdwNumHeaps and pdwNumFourCC, respectively.
    2. For each VIDEOMEMORY structure in the list to which pvmList points, fill in the appropriate members to describe a particular chunk of display memory. The list of structures provides DirectDraw with a complete description of the driver's offscreen memory.
  • Initialize the members of the DD_HALINFO structure with driver-specific information as follows:
    1. Initialize the appropriate members of the VIDEOMEMORYINFO structure in vmiData to describe the general characteristics of the display's memory.
    2. Initialize the appropriate members of the DDCORECAPS structure in ddCaps to describe the capabilities of the hardware.
    3. If the driver implements a DdGetDriverInfo function, set GetDriverInfo to point to it and set dwFlags to DDHALINFO_GETDRIVERINFOSET.

Requirements

Requirement Value
Target Platform Desktop
Header winddi.h (include Winddi.h)

See also

DD_HALINFO

DdGetDriverInfo

DrvEnableDirectDraw

VIDEOMEMORY

VIDEOMEMORYINFO