2 * DirectDraw driver interface
5 * Copyright (C) 2001 Ove Kaaven
7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Lesser General Public
9 * License as published by the Free Software Foundation; either
10 * version 2.1 of the License, or (at your option) any later version.
12 * This library is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * Lesser General Public License for more details.
17 * You should have received a copy of the GNU Lesser General Public
18 * License along with this library; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
22 #ifndef __WINE_DDRAWI_H
23 #define __WINE_DDRAWI_H
26 #include <dciddi.h> /* the DD HAL is layered onto DCI escapes */
32 typedef struct _DDVIDEOPORTCAPS
*LPDDVIDEOPORTCAPS
; /* should be in dvp.h */
33 typedef struct _DDKERNELCAPS
*LPDDKERNELCAPS
; /* should be in ddkernel.h */
34 typedef struct _VMEMHEAP
*LPVMEMHEAP
; /* should be in dmemmgr.h */
38 /* the DirectDraw versions */
39 #define DD_VERSION 0x0200 /* compatibility version */
40 #define DD_RUNTIME_VERSION 0x0700 /* actual version */
42 /* the HAL version returned from QUERYESCSUPPORT - DCICOMMAND */
43 #define DD_HAL_VERSION 0x0100
45 /* more DCICOMMAND escapes */
46 #define DDCREATEDRIVEROBJECT 10
47 #define DDGET32BITDRIVERNAME 11
48 #define DDNEWCALLBACKFNS 12
49 #define DDVERSIONINFO 13
51 #define MAX_DRIVER_NAME CCHDEVICENAME
53 /*****************************************************************************
54 * Initialization stuff
58 char szEntryPoint
[64];
60 } DD32BITDRIVERDATA
,*LPDD32BITDRIVERDATA
;
64 ULONG_PTR dwReserved1
;
65 ULONG_PTR dwReserved2
;
66 } DDVERSIONDATA
,*LPDDVERSIONDATA
;
68 typedef DWORD (PASCAL
*LPDD32BITDRIVERINIT
)(DWORD dwContext
);
70 /* pointer to video memory */
71 typedef ULONG_PTR FLATPTR
;
73 /* predeclare some structures */
74 typedef struct _DDHALINFO
*LPDDHALINFO
;
75 typedef struct _DDRAWI_DIRECTDRAW_INT
*LPDDRAWI_DIRECTDRAW_INT
;
76 typedef struct _DDRAWI_DIRECTDRAW_LCL
*LPDDRAWI_DIRECTDRAW_LCL
;
77 typedef struct _DDRAWI_DIRECTDRAW_GBL
*LPDDRAWI_DIRECTDRAW_GBL
;
78 typedef struct _DDRAWI_DDRAWSURFACE_INT
*LPDDRAWI_DDRAWSURFACE_INT
;
79 typedef struct _DDRAWI_DDRAWSURFACE_LCL
*LPDDRAWI_DDRAWSURFACE_LCL
;
80 typedef struct _DDRAWI_DDRAWSURFACE_GBL
*LPDDRAWI_DDRAWSURFACE_GBL
;
81 typedef struct _DDRAWI_DDRAWSURFACE_MORE
*LPDDRAWI_DDRAWSURFACE_MORE
;
82 typedef struct _DDRAWI_DDRAWSURFACE_GBL_MORE
*LPDDRAWI_DDRAWSURFACE_GBL_MORE
;
83 typedef struct _DDRAWI_DDRAWPALETTE_INT
*LPDDRAWI_DDRAWPALETTE_INT
;
84 typedef struct _DDRAWI_DDRAWPALETTE_LCL
*LPDDRAWI_DDRAWPALETTE_LCL
;
85 typedef struct _DDRAWI_DDRAWPALETTE_GBL
*LPDDRAWI_DDRAWPALETTE_GBL
;
86 typedef struct _DDRAWI_DDRAWCLIPPER_INT
*LPDDRAWI_DDRAWCLIPPER_INT
;
87 typedef struct _DDRAWI_DDRAWCLIPPER_LCL
*LPDDRAWI_DDRAWCLIPPER_LCL
;
88 typedef struct _DDRAWI_DDRAWCLIPPER_GBL
*LPDDRAWI_DDRAWCLIPPER_GBL
;
89 typedef struct _DDRAWI_DDVIDEOPORT_INT
*LPDDRAWI_DDVIDEOPORT_INT
;
90 typedef struct _DDRAWI_DDVIDEOPORT_LCL
*LPDDRAWI_DDVIDEOPORT_LCL
;
91 typedef struct _DDRAWI_DDMOTIONCOMP_INT
*LPDDRAWI_DDMOTIONCOMP_INT
;
92 typedef struct _DDRAWI_DDMOTIONCOMP_LCL
*LPDDRAWI_DDMOTIONCOMP_LCL
;
94 /* structure GUIDs for GetDriverInfo */
95 DEFINE_GUID( GUID_MiscellaneousCallbacks
, 0xEFD60CC0,0x49E7,0x11D0,0x88,0x9D,0x00,0xAA,0x00,0xBB,0xB7,0x6A );
96 /* ...videport stuff here... */
97 DEFINE_GUID( GUID_D3DCallbacks2
, 0x0BA584E1,0x70B6,0x11D0,0x88,0x9D,0x00,0xAA,0x00,0xBB,0xB7,0x6A );
98 DEFINE_GUID( GUID_D3DCallbacks3
, 0xDDF41230,0xEC0A,0x11D0,0xA9,0xB6,0x00,0xAA,0x00,0xC0,0x99,0x3E );
99 DEFINE_GUID( GUID_NonLocalVidMemCaps
, 0x86C4FA80,0x8D84,0x11D0,0x94,0xE8,0x00,0xC0,0x4F,0xC3,0x41,0x37 );
100 /* ...kernel stuff here... */
101 DEFINE_GUID( GUID_D3DExtendedCaps
, 0x7DE41F80,0x9D93,0x11D0,0x89,0xAB,0x00,0xA0,0xC9,0x05,0x41,0x29 );
102 DEFINE_GUID( GUID_ZPixelFormats
, 0x93869880,0x36CF,0x11D1,0x9B,0x1B,0x00,0xAA,0x00,0xBB,0xB8,0xAE );
103 DEFINE_GUID( GUID_DDMoreSurfaceCaps
, 0x3B8A0466,0xF269,0x11D1,0x88,0x0B,0x00,0xC0,0x4F,0xD9,0x30,0xC5 );
104 DEFINE_GUID( GUID_DDStereoMode
, 0xF828169C,0xA8E8,0x11D2,0xA1,0xF2,0x00,0xA0,0xC9,0x83,0xEA,0xF6 );
105 /* ...more stuff here... */
106 DEFINE_GUID(GUID_D3DParseUnknownCommandCallback
,0x2E04FFA0,0x98E4,0x11D1,0x8C,0xE1,0x00,0xA0,0xC9,0x06,0x29,0xA8 );
107 /* ...motioncomp stuff here... */
108 DEFINE_GUID( GUID_Miscellaneous2Callbacks
, 0x406B2F00,0x3E5A,0x11D1,0xB6,0x40,0x00,0xAA,0x00,0xA1,0xF9,0x6A );
110 /*****************************************************************************
111 * driver->ddraw callbacks
113 typedef BOOL (DDAPI
*LPDDHAL_SETINFO
)(LPDDHALINFO lpDDHalInfo
, BOOL reset
);
114 typedef FLATPTR (DDAPI
*LPDDHAL_VIDMEMALLOC
)(LPDDRAWI_DIRECTDRAW_GBL lpDD
, int heap
, DWORD dwWidth
, DWORD dwHeight
);
115 typedef void (DDAPI
*LPDDHAL_VIDMEMFREE
)(LPDDRAWI_DIRECTDRAW_GBL lpDD
, int heap
, FLATPTR fpMem
);
119 LPDDHAL_SETINFO lpSetInfo
;
120 LPDDHAL_VIDMEMALLOC lpVidMemAlloc
;
121 LPDDHAL_VIDMEMFREE lpVidMemFree
;
122 } DDHALDDRAWFNS
,*LPDDHALDDRAWFNS
;
124 /*****************************************************************************
125 * mode info structure
127 typedef struct _DDHALMODEINFO
{
137 DWORD dwAlphaBitMask
;
138 } DDHALMODEINFO
,*LPDDHALMODEINFO
;
140 #define DDMODEINFO_PALETTIZED 0x0001
141 #define DDMODEINFO_MODEX 0x0002
142 #define DDMODEINFO_UNSUPPORTED 0x0004
143 #define DDMODEINFO_STANDARDVGA 0x0008
144 #define DDMODEINFO_MAXREFRESH 0x0010
145 #define DDMODEINFO_STEREO 0x0020
147 /*****************************************************************************
148 * video memory info structure
150 typedef struct _VIDMEM
{
165 #define VIDMEM_ISLINEAR 0x00000001
166 #define VIDMEM_ISRECTANGULAR 0x00000002
167 #define VIDMEM_ISHEAP 0x00000004
168 #define VIDMEM_ISNONLOCAL 0x00000008
169 #define VIDMEM_ISWC 0x00000010
170 #define VIDMEM_ISDISABLED 0x00000020
172 typedef struct _VIDMEMINFO
{
175 DWORD dwDisplayWidth
;
176 DWORD dwDisplayHeight
;
178 DDPIXELFORMAT ddpfDisplay
;
179 DWORD dwOffscreenAlign
;
180 DWORD dwOverlayAlign
;
181 DWORD dwTextureAlign
;
182 DWORD dwZBufferAlign
;
186 } VIDMEMINFO
,*LPVIDMEMINFO
;
188 typedef struct _HEAPALIAS
{
192 } HEAPALIAS
,*LPHEAPALIAS
;
194 typedef struct _HEAPALIASINFO
{
198 LPHEAPALIAS lpAliases
;
199 } HEAPALIASINFO
,*LPHEAPALIASINFO
;
201 #define HEAPALIASINFO_MAPPEDREAL 0x00000001
202 #define HEAPALIASINFO_MAPPEDDUMMY 0x00000002
204 /*****************************************************************************
205 * capabilities structures
207 typedef struct _DDCORECAPS
{
216 DWORD dwAlphaBltConstBitDepths
;
217 DWORD dwAlphaBltPixelBitDepths
;
218 DWORD dwAlphaBltSurfaceBitDepths
;
219 DWORD dwAlphaOverlayConstBitDepths
;
220 DWORD dwAlphaOverlayPixelBitDepths
;
221 DWORD dwAlphaOverlaySurfaceBitDepths
;
222 DWORD dwZBufferBitDepths
;
225 DWORD dwMaxVisibleOverlays
;
226 DWORD dwCurrVisibleOverlays
;
227 DWORD dwNumFourCCCodes
;
228 DWORD dwAlignBoundarySrc
;
229 DWORD dwAlignSizeSrc
;
230 DWORD dwAlignBoundaryDest
;
231 DWORD dwAlignSizeDest
;
232 DWORD dwAlignStrideAlign
;
233 DWORD dwRops
[DD_ROP_SPACE
];
235 DWORD dwMinOverlayStretch
;
236 DWORD dwMaxOverlayStretch
;
237 DWORD dwMinLiveVideoStretch
;
238 DWORD dwMaxLiveVideoStretch
;
239 DWORD dwMinHwCodecStretch
;
240 DWORD dwMaxHwCodecStretch
;
247 DWORD dwSVBRops
[DD_ROP_SPACE
];
251 DWORD dwVSBRops
[DD_ROP_SPACE
];
255 DWORD dwSSBRops
[DD_ROP_SPACE
];
256 DWORD dwMaxVideoPorts
;
257 DWORD dwCurrVideoPorts
;
259 } DDCORECAPS
,*LPDDCORECAPS
;
261 typedef struct _DDNONLOCALVIDMEMCAPS
{
265 DWORD dwNLVBCKeyCaps
;
267 DWORD dwNLVBRops
[DD_ROP_SPACE
];
268 } DDNONLOCALVIDMEMCAPS
,*LPDDNONLOCALVIDMEMCAPS
;
270 typedef struct _DDSCAPSEX
{
274 } DDSCAPSEX
,*LPDDSCAPSEX
;
276 #define DDSCAPS_EXECUTEBUFFER DDSCAPS_RESERVED2
277 #define DDSCAPS2_VERTEXBUFFER DDSCAPS2_RESERVED1
278 #define DDSCAPS2_COMMANDBUFFER DDSCAPS2_RESERVED2
280 /*****************************************************************************
281 * ddraw->driver callbacks
283 #define DDHAL_DRIVER_NOTHANDLED 0
284 #define DDHAL_DRIVER_HANDLED 1
285 #define DDHAL_DRIVER_NOCKEYHW 2
287 typedef struct _DDHAL_DESTROYDRIVERDATA
*LPDDHAL_DESTROYDRIVERDATA
;
288 typedef struct _DDHAL_CREATESURFACEDATA
*LPDDHAL_CREATESURFACEDATA
;
289 typedef struct _DDHAL_DRVSETCOLORKEYDATA
*LPDDHAL_DRVSETCOLORKEYDATA
;
290 typedef struct _DDHAL_SETMODEDATA
*LPDDHAL_SETMODEDATA
;
291 typedef struct _DDHAL_WAITFORVERTICALBLANKDATA
*LPDDHAL_WAITFORVERTICALBLANKDATA
;
292 typedef struct _DDHAL_CANCREATESURFACEDATA
*LPDDHAL_CANCREATESURFACEDATA
;
293 typedef struct _DDHAL_CREATEPALETTEDATA
*LPDDHAL_CREATEPALETTEDATA
;
294 typedef struct _DDHAL_GETSCANLINEDATA
*LPDDHAL_GETSCANLINEDATA
;
295 typedef struct _DDHAL_SETEXCLUSIVEMODEDATA
*LPDDHAL_SETEXCLUSIVEMODEDATA
;
296 typedef struct _DDHAL_FLIPTOGDISURFACEDATA
*LPDDHAL_FLIPTOGDISURFACEDATA
;
298 typedef DWORD (PASCAL
*LPDDHAL_DESTROYDRIVER
) (LPDDHAL_DESTROYDRIVERDATA
);
299 typedef DWORD (PASCAL
*LPDDHAL_CREATESURFACE
) (LPDDHAL_CREATESURFACEDATA
);
300 typedef DWORD (PASCAL
*LPDDHAL_SETCOLORKEY
) (LPDDHAL_DRVSETCOLORKEYDATA
);
301 typedef DWORD (PASCAL
*LPDDHAL_SETMODE
) (LPDDHAL_SETMODEDATA
);
302 typedef DWORD (PASCAL
*LPDDHAL_WAITFORVERTICALBLANK
)(LPDDHAL_WAITFORVERTICALBLANKDATA
);
303 typedef DWORD (PASCAL
*LPDDHAL_CANCREATESURFACE
) (LPDDHAL_CANCREATESURFACEDATA
);
304 typedef DWORD (PASCAL
*LPDDHAL_CREATEPALETTE
) (LPDDHAL_CREATEPALETTEDATA
);
305 typedef DWORD (PASCAL
*LPDDHAL_GETSCANLINE
) (LPDDHAL_GETSCANLINEDATA
);
306 typedef DWORD (PASCAL
*LPDDHAL_SETEXCLUSIVEMODE
) (LPDDHAL_SETEXCLUSIVEMODEDATA
);
307 typedef DWORD (PASCAL
*LPDDHAL_FLIPTOGDISURFACE
) (LPDDHAL_FLIPTOGDISURFACEDATA
);
309 typedef struct _DDHAL_DDCALLBACKS
{
312 LPDDHAL_DESTROYDRIVER DestroyDriver
;
313 LPDDHAL_CREATESURFACE CreateSurface
;
314 LPDDHAL_SETCOLORKEY SetColorKey
;
315 LPDDHAL_SETMODE SetMode
;
316 LPDDHAL_WAITFORVERTICALBLANK WaitForVerticalBlank
;
317 LPDDHAL_CANCREATESURFACE CanCreateSurface
;
318 LPDDHAL_CREATEPALETTE CreatePalette
;
319 LPDDHAL_GETSCANLINE GetScanLine
;
321 LPDDHAL_SETEXCLUSIVEMODE SetExclusiveMode
;
322 LPDDHAL_FLIPTOGDISURFACE FlipToGDISurface
;
323 } DDHAL_DDCALLBACKS
,*LPDDHAL_DDCALLBACKS
;
325 typedef struct _DDHAL_DESTROYSURFACEDATA
*LPDDHAL_DESTROYSURFACEDATA
;
326 typedef struct _DDHAL_FLIPDATA
*LPDDHAL_FLIPDATA
;
327 typedef struct _DDHAL_SETCLIPLISTDATA
*LPDDHAL_SETCLIPLISTDATA
;
328 typedef struct _DDHAL_LOCKDATA
*LPDDHAL_LOCKDATA
;
329 typedef struct _DDHAL_UNLOCKDATA
*LPDDHAL_UNLOCKDATA
;
330 typedef struct _DDHAL_BLTDATA
*LPDDHAL_BLTDATA
;
331 typedef struct _DDHAL_SETCOLORKEYDATA
*LPDDHAL_SETCOLORKEYDATA
;
332 typedef struct _DDHAL_ADDATTACHEDSURFACEDATA
*LPDDHAL_ADDATTACHEDSURFACEDATA
;
333 typedef struct _DDHAL_GETBLTSTATUSDATA
*LPDDHAL_GETBLTSTATUSDATA
;
334 typedef struct _DDHAL_GETFLIPSTATUSDATA
*LPDDHAL_GETFLIPSTATUSDATA
;
335 typedef struct _DDHAL_UPDATEOVERLAYDATA
*LPDDHAL_UPDATEOVERLAYDATA
;
336 typedef struct _DDHAL_SETOVERLAYPOSITIONDATA
*LPDDHAL_SETOVERLAYPOSITIONDATA
;
337 typedef struct _DDHAL_SETPALETTEDATA
*LPDDHAL_SETPALETTEDATA
;
339 typedef DWORD (PASCAL
*LPDDHALSURFCB_DESTROYSURFACE
) (LPDDHAL_DESTROYSURFACEDATA
);
340 typedef DWORD (PASCAL
*LPDDHALSURFCB_FLIP
) (LPDDHAL_FLIPDATA
);
341 typedef DWORD (PASCAL
*LPDDHALSURFCB_SETCLIPLIST
) (LPDDHAL_SETCLIPLISTDATA
);
342 typedef DWORD (PASCAL
*LPDDHALSURFCB_LOCK
) (LPDDHAL_LOCKDATA
);
343 typedef DWORD (PASCAL
*LPDDHALSURFCB_UNLOCK
) (LPDDHAL_UNLOCKDATA
);
344 typedef DWORD (PASCAL
*LPDDHALSURFCB_BLT
) (LPDDHAL_BLTDATA
);
345 typedef DWORD (PASCAL
*LPDDHALSURFCB_SETCOLORKEY
) (LPDDHAL_SETCOLORKEYDATA
);
346 typedef DWORD (PASCAL
*LPDDHALSURFCB_ADDATTACHEDSURFACE
)(LPDDHAL_ADDATTACHEDSURFACEDATA
);
347 typedef DWORD (PASCAL
*LPDDHALSURFCB_GETBLTSTATUS
) (LPDDHAL_GETBLTSTATUSDATA
);
348 typedef DWORD (PASCAL
*LPDDHALSURFCB_GETFLIPSTATUS
) (LPDDHAL_GETFLIPSTATUSDATA
);
349 typedef DWORD (PASCAL
*LPDDHALSURFCB_UPDATEOVERLAY
) (LPDDHAL_UPDATEOVERLAYDATA
);
350 typedef DWORD (PASCAL
*LPDDHALSURFCB_SETOVERLAYPOSITION
)(LPDDHAL_SETOVERLAYPOSITIONDATA
);
351 typedef DWORD (PASCAL
*LPDDHALSURFCB_SETPALETTE
) (LPDDHAL_SETPALETTEDATA
);
353 typedef struct _DDHAL_DDSURFACECALLBACKS
{
356 LPDDHALSURFCB_DESTROYSURFACE DestroySurface
;
357 LPDDHALSURFCB_FLIP Flip
;
358 LPDDHALSURFCB_SETCLIPLIST SetClipList
;
359 LPDDHALSURFCB_LOCK Lock
;
360 LPDDHALSURFCB_UNLOCK Unlock
;
361 LPDDHALSURFCB_BLT Blt
;
362 LPDDHALSURFCB_SETCOLORKEY SetColorKey
;
363 LPDDHALSURFCB_ADDATTACHEDSURFACE AddAttachedSurface
;
364 LPDDHALSURFCB_GETBLTSTATUS GetBltStatus
;
365 LPDDHALSURFCB_GETFLIPSTATUS GetFlipStatus
;
366 LPDDHALSURFCB_UPDATEOVERLAY UpdateOverlay
;
367 LPDDHALSURFCB_SETOVERLAYPOSITION SetOverlayPosition
;
369 LPDDHALSURFCB_SETPALETTE SetPalette
;
370 } DDHAL_DDSURFACECALLBACKS
,*LPDDHAL_DDSURFACECALLBACKS
;
372 typedef struct _DDHAL_DESTROYPALETTEDATA
*LPDDHAL_DESTROYPALETTEDATA
;
373 typedef struct _DDHAL_SETENTRIESDATA
*LPDDHAL_SETENTRIESDATA
;
375 typedef DWORD (PASCAL
*LPDDHALPALCB_DESTROYPALETTE
)(LPDDHAL_DESTROYPALETTEDATA
);
376 typedef DWORD (PASCAL
*LPDDHALPALCB_SETENTRIES
) (LPDDHAL_SETENTRIESDATA
);
378 typedef struct _DDHAL_DDPALETTECALLBACKS
{
381 LPDDHALPALCB_DESTROYPALETTE DestroyPalette
;
382 LPDDHALPALCB_SETENTRIES SetEntries
;
383 } DDHAL_DDPALETTECALLBACKS
,*LPDDHAL_DDPALETTECALLBACKS
;
385 typedef DWORD (PASCAL
*LPDDHALEXEBUFCB_CANCREATEEXEBUF
)(LPDDHAL_CANCREATESURFACEDATA
);
386 typedef DWORD (PASCAL
*LPDDHALEXEBUFCB_CREATEEXEBUF
) (LPDDHAL_CREATESURFACEDATA
);
387 typedef DWORD (PASCAL
*LPDDHALEXEBUFCB_DESTROYEXEBUF
) (LPDDHAL_DESTROYSURFACEDATA
);
388 typedef DWORD (PASCAL
*LPDDHALEXEBUFCB_LOCKEXEBUF
) (LPDDHAL_LOCKDATA
);
389 typedef DWORD (PASCAL
*LPDDHALEXEBUFCB_UNLOCKEXEBUF
) (LPDDHAL_UNLOCKDATA
);
391 typedef struct _DDHAL_DDEXEBUFCALLBACKS
{
394 LPDDHALEXEBUFCB_CANCREATEEXEBUF CanCreateExecuteBuffer
;
395 LPDDHALEXEBUFCB_CREATEEXEBUF CreateExecuteBuffer
;
396 LPDDHALEXEBUFCB_DESTROYEXEBUF DestroyExecuteBuffer
;
397 LPDDHALEXEBUFCB_LOCKEXEBUF LockExecuteBuffer
;
398 LPDDHALEXEBUFCB_UNLOCKEXEBUF UnlockExecuteBuffer
;
399 } DDHAL_DDEXEBUFCALLBACKS
,*LPDDHAL_DDEXEBUFCALLBACKS
;
401 typedef struct _DDHAL_GETAVAILDRIVERMEMORYDATA
*LPDDHAL_GETAVAILDRIVERMEMORYDATA
;
402 typedef struct _DDHAL_UPDATENONLOCALHEAPDATA
*LPDDHAL_UPDATENONLOCALHEAPDATA
;
403 typedef struct _DDHAL_GETHEAPALIGNMENTDATA
*LPDDHAL_GETHEAPALIGNMENTDATA
;
405 typedef DWORD (PASCAL
*LPDDHAL_GETAVAILDRIVERMEMORY
)(LPDDHAL_GETAVAILDRIVERMEMORYDATA
);
406 typedef DWORD (PASCAL
*LPDDHAL_UPDATENONLOCALHEAP
) (LPDDHAL_UPDATENONLOCALHEAPDATA
);
407 typedef DWORD (PASCAL
*LPDDHAL_GETHEAPALIGNMENT
) (LPDDHAL_GETHEAPALIGNMENTDATA
);
409 typedef struct _DDHAL_DDMISCELLANEOUSCALLBACKS
{
412 LPDDHAL_GETAVAILDRIVERMEMORY GetAvailDriverMemory
;
413 LPDDHAL_UPDATENONLOCALHEAP UpdateNonLocalHeap
;
414 LPDDHAL_GETHEAPALIGNMENT GetHeapAlignment
;
415 LPDDHALSURFCB_GETBLTSTATUS GetSysmemBltStatus
;
416 } DDHAL_DDMISCELLANEOUSCALLBACKS
,*LPDDHAL_DDMISCELLANEOUSCALLBACKS
;
418 typedef struct _DDHAL_CREATESURFACEEXDATA
*LPDDHAL_CREATESURFACEEXDATA
;
419 typedef struct _DDHAL_GETDRIVERSTATEDATA
*LPDDHAL_GETDRIVERSTATEDATA
;
420 typedef struct _DDHAL_DESTROYDDLOCALDATA
*LPDDHAL_DESTROYDDLOCALDATA
;
422 typedef DWORD (PASCAL
*LPDDHAL_CREATESURFACEEX
)(LPDDHAL_CREATESURFACEEXDATA
);
423 typedef DWORD (PASCAL
*LPDDHAL_GETDRIVERSTATE
) (LPDDHAL_GETDRIVERSTATEDATA
);
424 typedef DWORD (PASCAL
*LPDDHAL_DESTROYDDLOCAL
) (LPDDHAL_DESTROYDDLOCALDATA
);
426 typedef struct _DDHAL_DDMISCELLANEOUS2CALLBACKS
{
430 LPDDHAL_CREATESURFACEEX CreateSurfaceEx
;
431 LPDDHAL_GETDRIVERSTATE GetDriverState
;
432 LPDDHAL_DESTROYDDLOCAL DestroyDDLocal
;
433 } DDHAL_DDMISCELLANEOUS2CALLBACKS
,*LPDDHAL_DDMISCELLANEOUS2CALLBACKS
;
435 typedef HRESULT (WINAPI
*LPDDGAMMACALIBRATORPROC
)(LPDDGAMMARAMP
, LPBYTE
);
437 /*****************************************************************************
438 * driver info structure
440 * The HAL is queried for additional callbacks via the GetDriverInfo callback.
442 typedef struct _DDHAL_GETDRIVERINFODATA
*LPDDHAL_GETDRIVERINFODATA
;
443 typedef DWORD (PASCAL
*LPDDHAL_GETDRIVERINFO
)(LPDDHAL_GETDRIVERINFODATA
);
445 typedef struct _DDHALINFO
{
447 LPDDHAL_DDCALLBACKS lpDDCallbacks
;
448 LPDDHAL_DDSURFACECALLBACKS lpDDSurfaceCallbacks
;
449 LPDDHAL_DDPALETTECALLBACKS lpDDPaletteCallbacks
;
452 DWORD dwMonitorFrequency
;
453 LPDDHAL_GETDRIVERINFO GetDriverInfo
;
457 LPDDHALMODEINFO lpModeInfo
;
462 ULONG_PTR lpD3DGlobalDriverData
;
463 ULONG_PTR lpD3DHALCallbacks
;
464 LPDDHAL_DDEXEBUFCALLBACKS lpDDExeBufCallbacks
;
467 #define DDHALINFO_ISPRIMARYDISPLAY 0x00000001
468 #define DDHALINFO_MODEXILLEGAL 0x00000002
469 #define DDHALINFO_GETDRIVERINFOSET 0x00000004
471 /* where the high-level ddraw implementation stores the callbacks */
472 typedef struct _DDHAL_CALLBACKS
{
473 DDHAL_DDCALLBACKS cbDDCallbacks
;
474 DDHAL_DDSURFACECALLBACKS cbDDSurfaceCallbacks
;
475 DDHAL_DDPALETTECALLBACKS cbDDPaletteCallbacks
;
476 DDHAL_DDCALLBACKS HALDD
;
477 DDHAL_DDSURFACECALLBACKS HALDDSurface
;
478 DDHAL_DDPALETTECALLBACKS HALDDPalette
;
479 DDHAL_DDCALLBACKS HELDD
;
480 DDHAL_DDSURFACECALLBACKS HELDDSurface
;
481 DDHAL_DDPALETTECALLBACKS HELDDPalette
;
482 DDHAL_DDEXEBUFCALLBACKS cbDDExeBufCallbacks
;
483 DDHAL_DDEXEBUFCALLBACKS HALDDExeBuf
;
484 DDHAL_DDEXEBUFCALLBACKS HELDDExeBuf
;
485 /* there's more... videoport, colorcontrol, misc, and motion compensation callbacks... */
486 } DDHAL_CALLBACKS
,*LPDDHAL_CALLBACKS
;
488 /*****************************************************************************
489 * parameter structures
491 typedef struct _DDHAL_DESTROYDRIVERDATA
{
492 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
494 LPDDHAL_DESTROYDRIVER DestroyDriver
;
495 } DDHAL_DESTROYDRIVERDATA
;
497 typedef struct _DDHAL_SETMODEDATA
{
498 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
501 LPDDHAL_SETMODE SetMode
;
506 typedef struct _DDHAL_CREATESURFACEDATA
{
507 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
508 LPDDSURFACEDESC lpDDSurfaceDesc
;
509 LPDDRAWI_DDRAWSURFACE_LCL
* lplpSList
;
512 LPDDHAL_CREATESURFACE CreateSurface
;
513 } DDHAL_CREATESURFACEDATA
;
515 typedef struct _DDHAL_CANCREATESURFACEDATA
{
516 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
517 LPDDSURFACEDESC lpDDSurfaceDesc
;
518 DWORD bIsDifferentPixelFormat
;
520 LPDDHAL_CANCREATESURFACE CanCreateSurface
;
521 } DDHAL_CANCREATESURFACEDATA
;
523 typedef struct _DDHAL_CREATEPALETTEDATA
{
524 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
525 LPDDRAWI_DDRAWPALETTE_GBL lpDDPalette
;
526 LPPALETTEENTRY lpColorTable
;
528 LPDDHAL_CREATEPALETTE CreatePalette
;
530 } DDHAL_CREATEPALETTEDATA
;
532 typedef struct _DDHAL_SETEXCLUSIVEMODEDATA
{
533 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
537 LPDDHAL_SETEXCLUSIVEMODE SetExclusiveMode
;
538 } DDHAL_SETEXCLUSIVEMODEDATA
;
541 typedef struct _DDHAL_DESTROYSURFACEDATA
{
542 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
543 LPDDRAWI_DDRAWSURFACE_LCL lpDDSurface
;
545 LPDDHALSURFCB_DESTROYSURFACE DestroySurface
;
546 } DDHAL_DESTROYSURFACEDATA
;
548 typedef struct _DDHAL_FLIPDATA
{
549 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
550 LPDDRAWI_DDRAWSURFACE_LCL lpSurfCurr
;
551 LPDDRAWI_DDRAWSURFACE_LCL lpSurfTarg
;
554 LPDDHALSURFCB_FLIP Flip
;
555 LPDDRAWI_DDRAWSURFACE_LCL lpSurfCurrLeft
;
556 LPDDRAWI_DDRAWSURFACE_LCL lpSurfTargLeft
;
559 typedef struct _DDHAL_LOCKDATA
{
560 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
561 LPDDRAWI_DDRAWSURFACE_LCL lpDDSurface
;
566 LPDDHALSURFCB_LOCK Lock
;
570 typedef struct _DDHAL_UNLOCKDATA
{
571 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
572 LPDDRAWI_DDRAWSURFACE_LCL lpDDSurface
;
574 LPDDHALSURFCB_UNLOCK Unlock
;
577 typedef struct _DDHAL_BLTDATA
{
578 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
579 LPDDRAWI_DDRAWSURFACE_LCL lpDDDestSurface
;
581 LPDDRAWI_DDRAWSURFACE_LCL lpDDSrcSurface
;
587 LPDDHALSURFCB_BLT Blt
;
595 typedef struct _DDHAL_UPDATEOVERLAYDATA
{
596 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
597 LPDDRAWI_DDRAWSURFACE_LCL lpDDDestSurface
;
599 LPDDRAWI_DDRAWSURFACE_LCL lpDDSrcSurface
;
602 DDOVERLAYFX overlayFX
;
604 LPDDHALSURFCB_UPDATEOVERLAY UpdateOverlay
;
605 } DDHAL_UPDATEOVERLAYDATA
;
607 typedef struct _DDHAL_SETPALETTEDATA
{
608 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
609 LPDDRAWI_DDRAWSURFACE_LCL lpDDSurface
;
610 LPDDRAWI_DDRAWPALETTE_GBL lpDDPalette
;
612 LPDDHALSURFCB_SETPALETTE SetPalette
;
614 } DDHAL_SETPALETTEDATA
;
617 typedef struct _DDHAL_DESTROYPALETTEDATA
{
618 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
619 LPDDRAWI_DDRAWPALETTE_GBL lpDDPalette
;
621 LPDDHALPALCB_DESTROYPALETTE DestroyPalette
;
622 } DDHAL_DESTROYPALETTEDATA
;
624 typedef struct _DDHAL_SETENTRIESDATA
{
625 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
626 LPDDRAWI_DDRAWPALETTE_GBL lpDDPalette
;
629 LPPALETTEENTRY lpEntries
;
631 LPDDHALPALCB_SETENTRIES SetEntries
;
632 } DDHAL_SETENTRIESDATA
;
634 typedef struct _DDHAL_GETDRIVERINFODATA
{
638 DWORD dwExpectedSize
;
643 } DDHAL_GETDRIVERINFODATA
;
645 /*****************************************************************************
646 * high-level ddraw implementation structures
648 typedef struct _IUNKNOWN_LIST
{
649 struct _IUNKNOWN_LIST
* lpLink
;
651 IUnknown
* lpIUnknown
;
652 } IUNKNOWN_LIST
,*LPIUNKNOWN_LIST
;
654 typedef struct _PROCESS_LIST
{
655 struct _PROCESS_LIST
* lpLink
;
660 } PROCESS_LIST
,*LPPROCESS_LIST
;
662 typedef struct _ATTACHLIST
{
664 struct _ATTACHLIST
* lpLink
;
665 LPDDRAWI_DDRAWSURFACE_LCL lpAttached
;
666 LPDDRAWI_DDRAWSURFACE_INT lpIAttached
;
667 } ATTACHLIST
,*LPATTACHLIST
;
669 #define DDAL_IMPLICIT 0x00000001
671 typedef struct _ACCESSRECTLIST
{
672 struct _ACCESSRECTLIST
* lpLink
;
674 LPDDRAWI_DIRECTDRAW_LCL lpOwner
;
675 LPVOID lpSurfaceData
;
677 LPHEAPALIASINFO lpHeapAliasInfo
;
678 } ACCESSRECTLIST
,*LPACCESSRECTLIST
;
680 #define ACCESSRECT_VRAMSTYLE 0x00000001
681 #define ACCESSRECT_NOTHOLDINGWIN16LOCK 0x00000002
682 #define ACCESSRECT_BROKEN 0x00000004
684 typedef struct _DBLNODE
{
685 struct _DBLNODE
* next
;
686 struct _DBLNODE
* prev
;
687 LPDDRAWI_DDRAWSURFACE_LCL object
;
688 LPDDRAWI_DDRAWSURFACE_INT object_int
;
689 } DBLNODE
,*LPDBLNODE
;
691 typedef struct _DDRAWI_DIRECTDRAW_INT
{
693 LPDDRAWI_DIRECTDRAW_LCL lpLcl
;
694 LPDDRAWI_DIRECTDRAW_INT lpLink
;
696 } DDRAWI_DIRECTDRAW_INT
;
698 typedef struct _DDRAWI_DIRECTDRAW_LCL
{
700 LPDDRAWI_DIRECTDRAW_GBL lpGbl
;
705 IUnknown
* pUnkOuter
;
710 LPDDRAWI_DDRAWSURFACE_INT lpPrimary
;
711 LPDDRAWI_DDRAWSURFACE_INT lpCB
;
712 DWORD dwPreferredMode
;
714 HINSTANCE hD3DInstance
;
715 IUnknown
* pD3DIUnknown
;
716 LPDDHAL_CALLBACKS lpDDCB
;
719 DWORD dwAppHackFlags
;
727 ULONG_PTR hGammaCalibrator
;
728 LPDDGAMMACALIBRATORPROC lpGammaCalibrator
;
729 } DDRAWI_DIRECTDRAW_LCL
;
731 #define DDRAWILCL_HASEXCLUSIVEMODE 0x00000001
732 #define DDRAWILCL_ISFULLSCREEN 0x00000002
733 #define DDRAWILCL_SETCOOPCALLED 0x00000004
734 #define DDRAWILCL_ACTIVEYES 0x00000008
735 #define DDRAWILCL_ACTIVENO 0x00000010
736 #define DDRAWILCL_HOOKEDHWND 0x00000020
737 #define DDRAWILCL_ALLOWMODEX 0x00000040
738 #define DDRAWILCL_V1SCLBEHAVIOUR 0x00000080
739 #define DDRAWILCL_MODEHASBEENCHANGED 0x00000100
740 #define DDRAWILCL_CREATEDWINDOW 0x00000200
741 #define DDRAWILCL_DIRTYDC 0x00000400
742 #define DDRAWILCL_DISABLEINACTIVATE 0x00000800
743 #define DDRAWILCL_CURSORCLIPPED 0x00001000
744 #define DDRAWILCL_EXPLICITMONITOR 0x00002000
745 #define DDRAWILCL_MULTITHREADED 0x00004000
746 #define DDRAWILCL_FPUSETUP 0x00008000
747 #define DDRAWILCL_POWEREDDOWN 0x00010000
748 #define DDRAWILCL_DIRECTDRAW7 0x00020000
749 #define DDRAWILCL_ATTEMPTEDD3DCONTEXT 0x00040000
750 #define DDRAWILCL_FPUPRESERVE 0x00080000
752 typedef struct _DDRAWI_DIRECTDRAW_GBL
{
755 FLATPTR fpPrimaryOrig
;
759 LPDDHAL_CALLBACKS lpDDCBtmp
;
760 LPDDRAWI_DDRAWSURFACE_INT dsList
;
761 LPDDRAWI_DDRAWPALETTE_INT palList
;
762 LPDDRAWI_DDRAWCLIPPER_INT clipperList
;
763 LPDDRAWI_DIRECTDRAW_GBL lp16DD
;
765 DWORD dwCurrOverlays
;
766 DWORD dwMonitorFrequency
;
767 DDCORECAPS ddHELCaps
;
769 DDCOLORKEY ddckCKDestOverlay
;
770 DDCOLORKEY ddckCKSrcOverlay
;
772 LPVOID lpDriverHandle
;
773 LPDDRAWI_DIRECTDRAW_LCL lpExclusiveOwner
;
775 DWORD dwModeIndexOrig
;
779 LPDDHALMODEINFO lpModeInfo
;
780 PROCESS_LIST plProcessList
;
781 DWORD dwSurfaceLockCount
;
782 DWORD dwAliasedLockCnt
;
783 ULONG_PTR dwReserved3
;
788 DBLNODE dbnOverlayRoot
;
789 volatile LPWORD lpwPDeviceFlags
;
791 DWORD dwWin16LockCnt
;
795 DWORD dwSaveNumModes
;
797 ULONG_PTR lpD3DGlobalDriverData
;
798 ULONG_PTR lpD3DHALCallbacks
;
799 DDCORECAPS ddBothCaps
;
801 LPDDVIDEOPORTCAPS lpDDVideoPortCaps
;
802 LPDDRAWI_DDVIDEOPORT_INT dvpList
;
803 ULONG_PTR lpD3DHALCallbacks2
;
808 LPHEAPALIASINFO phaiHeapAliases
;
809 ULONG_PTR hKernelHandle
;
810 ULONG_PTR pfnNotifyProc
;
811 LPDDKERNELCAPS lpDDKernelCaps
;
812 LPDDNONLOCALVIDMEMCAPS lpddNLVCaps
;
813 LPDDNONLOCALVIDMEMCAPS lpddNLVHELCaps
;
814 LPDDNONLOCALVIDMEMCAPS lpddNLVBothCaps
;
815 ULONG_PTR lpD3DExtendedCaps
;
819 char cDriverName
[MAX_DRIVER_NAME
];
821 ULONG_PTR lpD3DHALCallbacks3
;
822 DWORD dwNumZPixelFormats
;
823 LPDDPIXELFORMAT lpZPixelFormats
;
824 LPDDRAWI_DDMOTIONCOMP_INT mcList
;
826 DDSCAPSEX ddsCapsMore
;
827 } DDRAWI_DIRECTDRAW_GBL
;
829 #define DDRAWI_VIRTUALDESKTOP 0x00000008
830 #define DDRAWI_MODEX 0x00000010
831 #define DDRAWI_DISPLAYDRV 0x00000020
832 #define DDRAWI_FULLSCREEN 0x00000040
833 #define DDRAWI_MODECHANGED 0x00000080
834 #define DDRAWI_NOHARDWARE 0x00000100
835 #define DDRAWI_PALETTEINIT 0x00000200
836 #define DDRAWI_NOEMULATION 0x00000400
840 typedef struct _DDRAWI_DDRAWSURFACE_INT
{
842 LPDDRAWI_DDRAWSURFACE_LCL lpLcl
;
843 LPDDRAWI_DDRAWSURFACE_INT lpLink
;
845 } DDRAWI_DDRAWSURFACE_INT
;
847 typedef struct _DDRAWI_DDRAWSURFACE_GBL
{
851 LPACCESSRECTLIST lpRectList
;
855 LPVMEMHEAP lpVidMemHeap
;
859 LPDDRAWI_DIRECTDRAW_GBL lpDD
;
870 ULONG_PTR dwReserved1
; /* for display driver use */
871 /* optional (defaults to primary surface pixelformat) */
872 DDPIXELFORMAT ddpfSurface
;
873 } DDRAWI_DDRAWSURFACE_GBL
;
875 #define DDRAWISURFGBL_MEMFREE 0x00000001
876 #define DDRAWISURFGBL_SYSMEMREQUESTED 0x00000002
877 #define DDRAWISURFGBL_ISGDISURFACE 0x00000004
878 #define DDRAWISURFGBL_SOFTWAREAUTOFLIP 0x00000008
879 #define DDRAWISURFGBL_LOCKNOTHOLDINGWIN16LOCK 0x00000010
880 #define DDRAWISURFGBL_LOCKVRAMSTYLE 0x00000020
881 #define DDRAWISURFGBL_LOCKBROKEN 0x00000040
882 #define DDRAWISURFGBL_IMPLICITHANDLE 0x00000080
883 #define DDRAWISURFGBL_ISCLIENTMEM 0x00000100
884 #define DDRAWISURFGBL_HARDWAREOPSOURCE 0x00000200
885 #define DDRAWISURFGBL_HARDWAREOPDEST 0x00000400
886 #define DDRAWISURFGBL_HARDWAREOPSTARTED 0x00000600
887 #define DDRAWISURFGBL_VPORTINTERLEAVED 0x00000800
888 #define DDRAWISURFGBL_VPORTDATA 0x00001000
889 #define DDRAWISURFGBL_LATEALLOCATELINEAR 0x00002000
890 #define DDRAWISURFGBL_SYSMEMEXECUTEBUFFER 0x00004000
891 #define DDRAWISURFGBL_FASTLOCKHELD 0x00008000
892 #define DDRAWISURFGBL_READONLYLOCKHELD 0x00010000
894 typedef struct _DDRAWI_DDRAWSURFACE_GBL_MORE
{
897 DWORD dwPhysicalPageTable
;
898 FLATPTR fpPhysicalVidMem
;
902 ULONG_PTR dwSavedDCContext
;
903 FLATPTR fpAliasedVidMem
;
904 ULONG_PTR dwDriverReserved
;
905 ULONG_PTR dwHELReserved
;
907 ULONG_PTR hKernelSurface
;
908 DWORD dwKernelRefCnt
;
909 LPDDCOLORCONTROL lpColorInfo
;
911 DWORD dwContentsStamp
;
912 LPVOID lpvUnswappedDriverReserved
;
913 LPVOID lpDDRAWReserved2
;
914 DWORD dwDDRAWReserved1
;
915 DWORD dwDDRAWReserved2
;
916 FLATPTR fpAliasOfVidMem
;
917 } DDRAWI_DDRAWSURFACE_GBL_MORE
;
919 /* the MS version of this macro was somewhat obfuscated and unreadable
920 * (possibly because of mediocre MS coders)... so I simplified it...
921 * (and so I commit no copyright violations either, hah) */
922 #define GET_LPDDRAWSURFACE_GBL_MORE(psurf_gbl) \
923 (*(((LPDDRAWI_DDRAWSURFACE_GBL_MORE *)(psurf_gbl)) - 1))
925 typedef struct _DDRAWI_DDRAWSURFACE_MORE
{
927 IUNKNOWN_LIST
* lpIUnknowns
;
928 LPDDRAWI_DIRECTDRAW_LCL lpDD_lcl
;
929 DWORD dwPageLockCount
;
930 DWORD dwBytesAllocated
;
931 LPDDRAWI_DIRECTDRAW_INT lpDD_int
;
933 LPDDRAWI_DDRAWCLIPPER_INT lpDDIClipper
;
935 LPHEAPALIASINFO lpHeapAliasInfo
;
936 DWORD dwOverlayFlags
;
938 LPDDRAWI_DDVIDEOPORT_LCL lpVideoPort
;
939 LPDDOVERLAYFX lpddOverlayFX
;
941 DWORD dwTextureStage
;
942 LPVOID lpDDRAWReserved
;
943 LPVOID lpDDRAWReserved2
;
944 LPVOID lpDDrawReserved3
;
945 DWORD dwDDrawReserved4
;
946 LPVOID lpDDrawReserved5
;
948 LPDWORD lpOriginalGammaRamp
;
949 LPVOID lpDDrawReserved6
;
950 DWORD dwSurfaceHandle
;
951 DWORD qwDDrawReserved8
[2];
952 LPVOID lpDDrawReserved9
;
954 LPDDSURFACEDESC2 pCreatedDDSurfaceDesc2
;
955 LPDDRAWI_DDRAWSURFACE_LCL
*slist
;
958 } DDRAWI_DDRAWSURFACE_MORE
;
960 typedef struct _DDRAWI_DDRAWSURFACE_LCL
{
961 LPDDRAWI_DDRAWSURFACE_MORE lpSurfMore
;
962 LPDDRAWI_DDRAWSURFACE_GBL lpGbl
;
963 ULONG_PTR hDDSurface
;
964 LPATTACHLIST lpAttachList
;
965 LPATTACHLIST lpAttachListFrom
;
970 LPDDRAWI_DDRAWPALETTE_INT lpDDPalette
;
971 LPDDRAWI_DDRAWCLIPPER_LCL lpDDClipper
;
972 DWORD dwModeCreatedIn
;
973 DWORD dwBackBufferCount
;
974 DDCOLORKEY ddckCKDestBlt
;
975 DDCOLORKEY ddckCKSrcBlt
;
977 ULONG_PTR dwReserved1
; /* for display driver use */
979 DDCOLORKEY ddckCKSrcOverlay
;
980 DDCOLORKEY ddckCKDestOverlay
;
981 LPDDRAWI_DDRAWSURFACE_INT lpSurfaceOverlaying
;
982 DBLNODE dbnOverlayNode
;
989 } DDRAWI_DDRAWSURFACE_LCL
;
991 #define DDRAWISURF_ATTACHED 0x00000001
992 #define DDRAWISURF_IMPLICITCREATE 0x00000002
993 #define DDRAWISURF_ISFREE 0x00000004
994 #define DDRAWISURF_ATTACHED_FROM 0x00000008
995 #define DDRAWISURF_IMPLICITROOT 0x00000010
996 #define DDRAWISURF_PARTOFPRIMARYCHAIN 0x00000020
997 #define DDRAWISURF_DATAISALIASED 0x00000040
998 #define DDRAWISURF_HASDC 0x00000080
999 #define DDRAWISURF_HASCKEYDESTOVERLAY 0x00000100
1000 #define DDRAWISURF_HASCKEYDESTBLT 0x00000200
1001 #define DDRAWISURF_HASCKEYSRCOVERLAY 0x00000400
1002 #define DDRAWISURF_HASCKEYSRCBLT 0x00000800
1003 #define DDRAWISURF_LOCKEXCLUDEDCURSOR 0x00001000
1004 #define DDRAWISURF_HASPIXELFORMAT 0x00002000
1005 #define DDRAWISURF_HASOVERLAYDATA 0x00004000
1006 #define DDRAWISURF_SETGAMMA 0x00008000
1008 #define DDRAWISURF_INVALID 0x10000000
1011 typedef struct _DDRAWI_DDRAWPALETTE_INT
{
1013 LPDDRAWI_DDRAWPALETTE_LCL lpLcl
;
1014 LPDDRAWI_DDRAWPALETTE_INT lpLink
;
1016 } DDRAWI_DDRAWPALETTE_INT
;
1018 typedef struct _DDRAWI_DDRAWPALETTE_GBL
{
1021 LPDDRAWI_DIRECTDRAW_LCL lpDD_lcl
;
1023 LPPALETTEENTRY lpColorTable
;
1025 ULONG_PTR dwReserved1
; /* for display driver use */
1026 HPALETTE hHELGDIPalette
;
1029 DWORD dwDriverReserved
;
1030 DWORD dwContentsStamp
;
1035 } DDRAWI_DDRAWPALETTE_GBL
;
1037 #define DDRAWIPAL_256 0x00000001
1038 #define DDRAWIPAL_16 0x00000002
1039 #define DDRAWIPAL_GDI 0x00000004
1040 #define DDRAWIPAL_STORED_8 0x00000008
1041 #define DDRAWIPAL_STORED_16 0x00000010
1042 #define DDRAWIPAL_STORED_24 0x00000020
1043 #define DDRAWIPAL_EXCLUSIVE 0x00000040
1044 #define DDRAWIPAL_INHEL 0x00000080
1045 #define DDRAWIPAL_DIRTY 0x00000100
1046 #define DDRAWIPAL_ALLOW256 0x00000200
1047 #define DDRAWIPAL_4 0x00000400
1048 #define DDRAWIPAL_2 0x00000800
1049 #define DDRAWIPAL_STORED_8INDEX 0x00001000
1050 #define DDRAWIPAL_ALPHA 0x00002000
1052 typedef struct _DDRAWI_DDRAWPALETTE_LCL
{
1054 LPDDRAWI_DDRAWPALETTE_GBL lpGbl
;
1055 ULONG_PTR dwUnused0
;
1056 DWORD dwLocalRefCnt
;
1057 IUnknown
* pUnkOuter
;
1058 LPDDRAWI_DIRECTDRAW_LCL lpDD_lcl
;
1059 ULONG_PTR dwReserved1
;
1061 ULONG_PTR dwDDRAWReserved1
;
1062 ULONG_PTR dwDDRAWReserved2
;
1063 ULONG_PTR dwDDRAWReserved3
;
1064 } DDRAWI_DDRAWPALETTE_LCL
;
1070 #endif /* __WINE_DDRAWI_H */