IDirectDrawSurface7::EnumOverlayZOrders method

Enumerates the overlay surfaces on the specified destination. You can enumerate the overlays in front-to-back or back-to-front order.

Syntax


HRESULT EnumOverlayZOrders(
  [in] DWORD                     dwFlags,
  [in] LPVOID                    lpContext,
  [in] LPDDENUMSURFACESCALLBACK7 lpfnCallback
);

Parameters

dwFlags [in]

A value that can be set to one of the following flags:

DDENUMOVERLAYZ_BACKTOFRONT

Enumerates overlays back to front.

DDENUMOVERLAYZ_FRONTTOBACK

Enumerates overlays front to back.

lpContext [in]

Address of the user-defined structure to be passed to the callback function for each overlay surface.

lpfnCallback [in]

Address of the EnumSurfacesCallback7 callback function to be called for each surface to be overlaid on this surface.

Return value

If the method succeeds, the return value is DD_OK.

If it fails, the method can return one of the following error values:

  • DDERR_INVALIDOBJECT
  • DDERR_INVALIDPARAMS

Remarks

EnumOverlayZOrders differs from its counterparts in previous interface versions in that it accepts a pointer to an EnumSurfacesCallback7 function, rather than an EnumSurfacesCallback or EnumSurfacesCallback2 function.

You must use LoadLibrary to explicitly link to Ddraw.dll and then use GetProcAddress to access the EnumOverlayZOrders method.

Requirements

Header

Ddraw.h

Library

Ddraw.lib

DLL

Ddraw.dll

See also

IDirectDrawSurface7

 

 

Show: