Export (0) Print
Expand All
Expand Minimize
This topic has not yet been rated - Rate this topic

DdQueryDirectDrawObject function

[This function is subject to change with each operating system revision. Instead, use the Microsoft DirectDraw and Microsoft Direct3DAPIs; these APIs insulate applications from such operating system changes, and hide many other difficulties involved in interacting directly with display drivers. ]

Wrapper for the NtGdiDdQueryDirectDrawObject function and queries a previously created kernel-mode representation for capabilities.

GdiEntry2 is defined as an alias for this function.

Syntax


BOOL APIENTRY DdQueryDirectDrawObject(
  LPDDRAWI_DIRECTDRAW_GBL pDirectDrawGlobal,
  LPDDHALINFO pHalInfo,
  LPDDHAL_DDCALLBACKS pDDCallbacks,
  LPDDHAL_DDSURFACECALLBACKS pDDSurfaceCallbacks,
  LPDDHAL_DDPALETTECALLBACKS pDDPaletteCallbacks,
  LPD3DHAL_CALLBACKS pD3dCallbacks,
  LPD3DHAL_GLOBALDRIVERDATA pD3dDriverData,
  LPDDHAL_DDEXEBUFCALLBACKS pD3dBufferCallbacks,
  LPDDSURFACEDESC pD3dTextureFormats,
  LPDWORD pdwFourCC,
  LPVIDMEM pvmList
);

Parameters

pDirectDrawGlobal

Pointer to a user-mode DirectDraw object for which a kernel-side object was previously created with DdCreateDirectDrawObject.

pHalInfo

Pointer to a DDHALINFO structure that will be filled with the device's capabilities. See DDK documentation for details.

pDDCallbacks

Pointer to a table of callback pointers. The table is filled with pointers to functions within Gdi32.dll that imitate a DirectDraw display driver. This callback table is identical to the DDHAL_DDCALLBACKS structure, which maps to the DD_CALLBACKS structure discussed in the DDK documentation.

pDDSurfaceCallbacks

Pointer to a table of surface callback pointers. The table is filled with pointers to functions within Gdi32.dll that imitate a DirectDraw display driver. This callback table is identical to the DDHAL_DDSURFACECALLBACKS structure, which maps to the DD_SURFACECALLBACKS structure discussed in the DDK documentation.

pDDPaletteCallbacks

Pointer to a table of palette callback pointers. The table is filled with pointers to functions within Gdi32.dll that imitate a DirectDraw display driver. This callback table is identical to the DDHAL_DDPALETTECALLBACKS structure, which maps to the DD_PALETTECALLBACKS structure discussed in the DDK documentation.

pD3dCallbacks

Pointer to a table of Direct3D callback pointers. The table is filled with pointers to functions within Gdi32.dll that imitate a Direct3D display driver. This callback table is identical to the D3DHAL_CALLBACKS structure discussed in the DDK documentation.

pD3dDriverData

Pointer to D3DHAL_GLOBALDRIVERDATA data, as described in the DDK documentation.

pD3dBufferCallbacks

Pointer to a table of callback pointers. The table is filled with pointers to functions within Gdi32.dll that imitate a Direct3D display driver. This callback table is identical to the DDHAL_DDEXEBUFCALLBACKS structure, which maps to the DD_D3DBUFCALLBACKS structure discussed in the DDK documentation, except that members XxxD3DBuffer in DD_D3DBUFCALLBACKS are replaced with XxxExecuteBuffer in DDHAL_DDEXEBUFCALLBACKS.

pD3dTextureFormats

Pointer to an array of DDSURFACEDESC structures that define the set of permissible texture formats.

pdwFourCC

Pointer to a list of supported Four-Character Codes (FOURCC) surface formats. Can be NULL.

pvmList

Pointer to a list of video memory heap descriptors. Can be NULL. This parameter is not used because video memory management is handled entirely within kernel mode.

Return value

If successful, this function returns TRUE; otherwise it returns FALSE.

Remarks

A call to this function is designed to be made in a two-step process. In the first step, pdwFourCC, pvmList and pD3dTextureFormats should be NULL, and DdQueryDirectDrawObject will fill in DDHALINFO.ddCaps.dwNumFourCCCodes, DDHALINFO.vmiData.dwNumHeaps, and D3DHAL_GLOBALDRIVERDATA.dwNumTextureFormats with the number of entries that are to be returned. In the second call, the caller should allocate arrays of the indicated size and pass those pointers instead of NULL values in the pdwFourCC, pvmList and pD3dTextureFormats parameters. The arrays will then be populated with appropriate data.

Applications are advised to use the DirectDraw and Direct3D   APIs to create and manage graphics device objects. These constructs abstract the device creation process in a simplified and operating-system-independent way.

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Ddrawgdi.h

See also

Graphics Low Level Client Support

 

 

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.