DD_CALLBACKS structure (ddrawint.h)
The DD_CALLBACKS structure contains entry pointers to the callback functions that a device driver supports.
Syntax
typedef struct DD_CALLBACKS {
DWORD dwSize;
DWORD dwFlags;
PDD_DESTROYDRIVER DestroyDriver;
PDD_CREATESURFACE CreateSurface;
PDD_SETCOLORKEY SetColorKey;
PDD_SETMODE SetMode;
PDD_WAITFORVERTICALBLANK WaitForVerticalBlank;
PDD_CANCREATESURFACE CanCreateSurface;
PDD_CREATEPALETTE CreatePalette;
PDD_GETSCANLINE GetScanLine;
PDD_MAPMEMORY MapMemory;
} DD_CALLBACKS;
Members
dwSize
Specifies the size in bytes of this structure.
dwFlags
Indicates what Microsoft DirectDraw callback functions the driver has implemented. For every bit set in dwFlags, the driver must initialize the corresponding function pointer member of this structure. This member can be one or more of the following flags:
- DDHAL_CB32_CANCREATESURFACE
- DDHAL_CB32_CREATEPALETTE
- DDHAL_CB32_CREATESURFACE
- DDHAL_CB32_GETSCANLINE
- DDHAL_CB32_MAPMEMORY
- DDHAL_CB32_SETCOLORKEY
- DDHAL_CB32_SETMODE
- DDHAL_CB32_WAITFORVERTICALBLANK
DestroyDriver
Unused on Microsoft Windows 2000 and later and should be ignored by the driver.
CreateSurface
Points to the driver-supplied DdCreateSurface callback.
SetColorKey
Points to the driver-supplied DdSetColorKey callback.
SetMode
Unused on Windows 2000 and later and should be ignored by the driver.
WaitForVerticalBlank
Points to the driver-supplied DdWaitForVerticalBlank callback.
CanCreateSurface
Points to the driver-supplied DdCanCreateSurface callback.
CreatePalette
Points to the driver-supplied DdCreatePalette callback.
GetScanLine
Points to the driver-supplied DdGetScanLine callback.
MapMemory
Points to the driver-supplied DdMapMemory callback.
Remarks
Entries that the display driver does not use should be set to NULL. GDI allocates the memory for this structure and calls the driver's DrvEnableDirectDraw function to initialize it.
Requirements
Requirement | Value |
---|---|
Header | ddrawint.h (include Winddi.h) |