DDREGISTERCALLBACK structure (ddkmapi.h)

The DDREGISTERCALLBACK structure contains the register callback information. This structure is used by both the DD_DXAPI_REGISTER_CALLBACK and DD_DXAPI_UNREGISTER_CALLBACK function identifiers of the DxApi function.

Syntax

typedef struct _DDREGISTERCALLBACK {
  HANDLE              hDirectDraw;
  ULONG               dwEvents;
  LPDD_NOTIFYCALLBACK pfnCallback;
  ULONG_PTR           dwParam1;
  ULONG_PTR           dwParam2;
  PVOID               pContext;
} DDREGISTERCALLBACK, *LPDDREGISTERCALLBACK;

Members

hDirectDraw

Specifies the Microsoft DirectDraw handle.

dwEvents

Defines the event that should trigger the callback. The values in dwParam1 and dwParam2 depend on the event. The following events are defined:

Event Description dwParam1,dwParam2
DDEVENT_DISPLAY_VSYNC Called every time a display V-sync occurs.
unused,
unused
DDEVENT_POSTDOSBOX Called after returning from a full-screen MS-DOS box or the security dialog box (appears when CTRL+ALT+DELETE is pressed).
unused,
unused
DDEVENT_POSTRESCHANGE Called after a mode change occurs.
unused,
unused
DDEVENT_PREDOSBOX Called before entering a full-screen MS-DOS box or the security dialog box (appears when CTRL+ALT+DELETE is pressed).
unused,
unused
DDEVENT_PRERESCHANGE Called before a mode change occurs.
unused,
unused
DDEVENT_VP_LINE Sets an IRQ to occur each time the hardware video port writes the specified line and then calls the callback each time the IRQ is triggered.
hVideoPort,
line
DDEVENT_VP_VSYNC Called each time a hardware video port V-sync occurs.
hVideoPort,
unused

pfnCallback

Points to a pfnCallback callback function that is called when the event that is specified by the dwEvents member occurs.

dwParam1

Defined by the dwEvents member.

dwParam2

Defined by the dwEvents member.

pContext

Contains client data that is passed back to the client if the pfnCallback callback function is called.

Requirements

Requirement Value
Header ddkmapi.h (include Ddkmapi.h)

See also

DD_DXAPI_REGISTER_CALLBACK

DD_DXAPI_UNREGISTER_CALLBACK

DxApi