1 /* Direct Draw Thunks and old vtables
2 * Copyright 2000 TransGaming Technologies Inc.
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
20 #include "wine/port.h"
28 #define NONAMELESSUNION
34 #include "wine/exception.h"
39 #include "ddraw_private.h"
40 #include "wine/debug.h"
42 WINE_DEFAULT_DEBUG_CHANNEL(ddraw_thunk
);
43 WINE_DECLARE_DEBUG_CHANNEL(ddraw
);
46 IDirectDrawImpl_QueryInterface(LPDIRECTDRAW This
, REFIID iid
, LPVOID
*ppObj
)
48 return IDirectDraw7_QueryInterface(COM_INTERFACE_CAST(IDirectDrawImpl
,
55 IDirectDraw2Impl_QueryInterface(LPDIRECTDRAW2 This
, REFIID iid
, LPVOID
*ppObj
)
57 return IDirectDraw7_QueryInterface(COM_INTERFACE_CAST(IDirectDrawImpl
,
64 IDirectDraw3Impl_QueryInterface(LPDIRECTDRAW3 This
, REFIID iid
, LPVOID
*ppObj
)
66 return IDirectDraw7_QueryInterface(COM_INTERFACE_CAST(IDirectDrawImpl
,
73 IDirectDraw4Impl_QueryInterface(LPDIRECTDRAW4 This
, REFIID iid
, LPVOID
*ppObj
)
75 return IDirectDraw7_QueryInterface(COM_INTERFACE_CAST(IDirectDrawImpl
,
82 IDirectDrawImpl_AddRef(LPDIRECTDRAW iface
)
84 ICOM_THIS_FROM(IDirectDrawImpl
, IDirectDraw
, iface
);
85 ULONG ref
= InterlockedIncrement(&This
->ref1
);
87 TRACE("(%p) : incrementing IDirectDraw refcount from %u.\n", This
, ref
-1);
89 if(ref
== 1) InterlockedIncrement(&This
->numIfaces
);
95 IDirectDraw2Impl_AddRef(LPDIRECTDRAW2 iface
)
97 ICOM_THIS_FROM(IDirectDrawImpl
, IDirectDraw2
, iface
);
98 ULONG ref
= InterlockedIncrement(&This
->ref2
);
100 TRACE("(%p) : incrementing IDirectDraw2 refcount from %u.\n", This
, ref
-1);
102 if(ref
== 1) InterlockedIncrement(&This
->numIfaces
);
108 IDirectDraw3Impl_AddRef(LPDIRECTDRAW3 iface
)
110 ICOM_THIS_FROM(IDirectDrawImpl
, IDirectDraw3
, iface
);
111 ULONG ref
= InterlockedIncrement(&This
->ref3
);
113 TRACE("(%p) : incrementing IDirectDraw3 refcount from %u.\n", This
, ref
-1);
115 if(ref
== 1) InterlockedIncrement(&This
->numIfaces
);
121 IDirectDraw4Impl_AddRef(LPDIRECTDRAW4 iface
)
123 ICOM_THIS_FROM(IDirectDrawImpl
, IDirectDraw4
, iface
);
124 ULONG ref
= InterlockedIncrement(&This
->ref4
);
126 TRACE("(%p) : incrementing IDirectDraw4 refcount from %u.\n", This
, ref
-1);
128 if(ref
== 1) InterlockedIncrement(&This
->numIfaces
);
134 IDirectDrawImpl_Release(LPDIRECTDRAW iface
)
136 ICOM_THIS_FROM(IDirectDrawImpl
, IDirectDraw
, iface
);
137 ULONG ref
= InterlockedDecrement(&This
->ref1
);
139 TRACE_(ddraw
)("(%p)->() decrementing IDirectDraw refcount from %u.\n", This
, ref
+1);
143 ULONG ifacecount
= InterlockedDecrement(&This
->numIfaces
);
144 if(ifacecount
== 0) IDirectDrawImpl_Destroy(This
);
151 IDirectDraw2Impl_Release(LPDIRECTDRAW2 iface
)
153 ICOM_THIS_FROM(IDirectDrawImpl
, IDirectDraw2
, iface
);
154 ULONG ref
= InterlockedDecrement(&This
->ref2
);
156 TRACE_(ddraw
)("(%p)->() decrementing IDirectDraw2 refcount from %u.\n", This
, ref
+1);
160 ULONG ifacecount
= InterlockedDecrement(&This
->numIfaces
);
161 if(ifacecount
== 0) IDirectDrawImpl_Destroy(This
);
168 IDirectDraw3Impl_Release(LPDIRECTDRAW3 iface
)
170 ICOM_THIS_FROM(IDirectDrawImpl
, IDirectDraw3
, iface
);
171 ULONG ref
= InterlockedDecrement(&This
->ref3
);
173 TRACE_(ddraw
)("(%p)->() decrementing IDirectDraw3 refcount from %u.\n", This
, ref
+1);
177 ULONG ifacecount
= InterlockedDecrement(&This
->numIfaces
);
178 if(ifacecount
== 0) IDirectDrawImpl_Destroy(This
);
185 IDirectDraw4Impl_Release(LPDIRECTDRAW4 iface
)
187 ICOM_THIS_FROM(IDirectDrawImpl
, IDirectDraw4
, iface
);
188 ULONG ref
= InterlockedDecrement(&This
->ref4
);
190 TRACE_(ddraw
)("(%p)->() decrementing IDirectDraw4 refcount from %u.\n", This
, ref
+1);
194 ULONG ifacecount
= InterlockedDecrement(&This
->numIfaces
);
195 if(ifacecount
== 0) IDirectDrawImpl_Destroy(This
);
201 static HRESULT WINAPI
202 IDirectDrawImpl_Compact(LPDIRECTDRAW This
)
204 return IDirectDraw7_Compact(COM_INTERFACE_CAST(IDirectDrawImpl
,
205 IDirectDraw
, IDirectDraw7
,
209 static HRESULT WINAPI
210 IDirectDraw2Impl_Compact(LPDIRECTDRAW2 This
)
212 return IDirectDraw7_Compact(COM_INTERFACE_CAST(IDirectDrawImpl
,
213 IDirectDraw2
, IDirectDraw7
,
217 static HRESULT WINAPI
218 IDirectDraw3Impl_Compact(LPDIRECTDRAW3 This
)
220 return IDirectDraw7_Compact(COM_INTERFACE_CAST(IDirectDrawImpl
,
221 IDirectDraw3
, IDirectDraw7
,
225 static HRESULT WINAPI
226 IDirectDraw4Impl_Compact(LPDIRECTDRAW4 This
)
228 return IDirectDraw7_Compact(COM_INTERFACE_CAST(IDirectDrawImpl
,
229 IDirectDraw4
, IDirectDraw7
,
233 static HRESULT WINAPI
234 IDirectDrawImpl_CreateClipper(LPDIRECTDRAW This
, DWORD dwFlags
,
235 LPDIRECTDRAWCLIPPER
*ppClipper
,
238 return IDirectDraw7_CreateClipper(COM_INTERFACE_CAST(IDirectDrawImpl
,
242 dwFlags
, ppClipper
, pUnkOuter
);
245 static HRESULT WINAPI
246 IDirectDraw2Impl_CreateClipper(LPDIRECTDRAW2 This
, DWORD dwFlags
,
247 LPDIRECTDRAWCLIPPER
*ppClipper
,
250 return IDirectDraw7_CreateClipper(COM_INTERFACE_CAST(IDirectDrawImpl
,
254 dwFlags
, ppClipper
, pUnkOuter
);
257 static HRESULT WINAPI
258 IDirectDraw3Impl_CreateClipper(LPDIRECTDRAW3 This
, DWORD dwFlags
,
259 LPDIRECTDRAWCLIPPER
*ppClipper
,
262 return IDirectDraw7_CreateClipper(COM_INTERFACE_CAST(IDirectDrawImpl
,
266 dwFlags
, ppClipper
, pUnkOuter
);
269 static HRESULT WINAPI
270 IDirectDraw4Impl_CreateClipper(LPDIRECTDRAW4 This
, DWORD dwFlags
,
271 LPDIRECTDRAWCLIPPER
*ppClipper
,
274 return IDirectDraw7_CreateClipper(COM_INTERFACE_CAST(IDirectDrawImpl
,
278 dwFlags
, ppClipper
, pUnkOuter
);
281 static HRESULT WINAPI
282 IDirectDrawImpl_CreatePalette(LPDIRECTDRAW This
, DWORD dwFlags
,
283 LPPALETTEENTRY pEntries
,
284 LPDIRECTDRAWPALETTE
*ppPalette
,
288 hr
= IDirectDraw7_CreatePalette(COM_INTERFACE_CAST(IDirectDrawImpl
,
292 dwFlags
, pEntries
, ppPalette
, pUnkOuter
);
293 if(SUCCEEDED(hr
) && *ppPalette
)
295 IDirectDrawPaletteImpl
*impl
= ICOM_OBJECT(IDirectDrawPaletteImpl
, IDirectDrawPalette
, *ppPalette
);
296 IDirectDraw7_Release(COM_INTERFACE_CAST(IDirectDrawImpl
,
300 impl
->ifaceToRelease
= NULL
;
306 static HRESULT WINAPI
307 IDirectDraw2Impl_CreatePalette(LPDIRECTDRAW2 This
, DWORD dwFlags
,
308 LPPALETTEENTRY pEntries
,
309 LPDIRECTDRAWPALETTE
*ppPalette
,
313 hr
= IDirectDraw7_CreatePalette(COM_INTERFACE_CAST(IDirectDrawImpl
,
317 dwFlags
, pEntries
, ppPalette
, pUnkOuter
);
318 if(SUCCEEDED(hr
) && *ppPalette
)
320 IDirectDrawPaletteImpl
*impl
= ICOM_OBJECT(IDirectDrawPaletteImpl
, IDirectDrawPalette
, *ppPalette
);
321 IDirectDraw7_Release(COM_INTERFACE_CAST(IDirectDrawImpl
,
325 impl
->ifaceToRelease
= NULL
;
330 static HRESULT WINAPI
331 IDirectDraw3Impl_CreatePalette(LPDIRECTDRAW3 This
, DWORD dwFlags
,
332 LPPALETTEENTRY pEntries
,
333 LPDIRECTDRAWPALETTE
*ppPalette
,
337 hr
= IDirectDraw7_CreatePalette(COM_INTERFACE_CAST(IDirectDrawImpl
,
341 dwFlags
, pEntries
, ppPalette
, pUnkOuter
);
342 if(SUCCEEDED(hr
) && *ppPalette
)
344 IDirectDrawPaletteImpl
*impl
= ICOM_OBJECT(IDirectDrawPaletteImpl
, IDirectDrawPalette
, *ppPalette
);
345 IDirectDraw7_Release(COM_INTERFACE_CAST(IDirectDrawImpl
,
349 IDirectDraw4_AddRef(This
);
350 impl
->ifaceToRelease
= (IUnknown
*) This
;
355 static HRESULT WINAPI
356 IDirectDraw4Impl_CreatePalette(LPDIRECTDRAW4 This
, DWORD dwFlags
,
357 LPPALETTEENTRY pEntries
,
358 LPDIRECTDRAWPALETTE
*ppPalette
,
362 hr
= IDirectDraw7_CreatePalette(COM_INTERFACE_CAST(IDirectDrawImpl
,
366 dwFlags
, pEntries
, ppPalette
, pUnkOuter
);
367 if(SUCCEEDED(hr
) && *ppPalette
)
369 IDirectDrawPaletteImpl
*impl
= ICOM_OBJECT(IDirectDrawPaletteImpl
, IDirectDrawPalette
, *ppPalette
);
370 IDirectDraw7_Release(COM_INTERFACE_CAST(IDirectDrawImpl
,
374 IDirectDraw4_AddRef(This
);
375 impl
->ifaceToRelease
= (IUnknown
*) This
;
380 static HRESULT WINAPI
381 IDirectDrawImpl_CreateSurface(LPDIRECTDRAW This
, LPDDSURFACEDESC pSDesc
,
382 LPDIRECTDRAWSURFACE
*ppSurface
,
385 LPDIRECTDRAWSURFACE7 pSurface7
;
386 IDirectDrawSurfaceImpl
*impl
;
389 /* Remove front buffer flag, this causes failure in v7, and its added to normal
392 pSDesc
->ddsCaps
.dwCaps
&= ~DDSCAPS_FRONTBUFFER
;
393 /* the LPDDSURFACEDESC -> LPDDSURFACEDESC2 conversion should be ok,
394 * since the data layout is the same */
395 hr
= IDirectDraw7_CreateSurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
399 (LPDDSURFACEDESC2
)pSDesc
, &pSurface7
, pUnkOuter
);
401 /* This coercion is safe, since the IDirectDrawSurface3 vtable has the
402 * IDirectDrawSurface vtable layout at the beginning */
403 *ppSurface
= (LPDIRECTDRAWSURFACE
) COM_INTERFACE_CAST(IDirectDrawSurfaceImpl
,
404 IDirectDrawSurface7
, IDirectDrawSurface3
,
407 impl
= ICOM_OBJECT(IDirectDrawSurfaceImpl
, IDirectDrawSurface7
, pSurface7
);
408 if(SUCCEEDED(hr
) && impl
)
411 IDirectDraw7_Release(COM_INTERFACE_CAST(IDirectDrawImpl
,
415 impl
->ifaceToRelease
= NULL
;
421 static HRESULT WINAPI
422 IDirectDraw2Impl_CreateSurface(LPDIRECTDRAW2 This
, LPDDSURFACEDESC pSDesc
,
423 LPDIRECTDRAWSURFACE
*ppSurface
,
426 LPDIRECTDRAWSURFACE7 pSurface7
;
427 IDirectDrawSurfaceImpl
*impl
;
430 hr
= IDirectDraw7_CreateSurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
434 (LPDDSURFACEDESC2
)pSDesc
, &pSurface7
, pUnkOuter
);
436 /* This coercion is safe, since the IDirectDrawSurface3 vtable has the
437 * IDirectDrawSurface vtable layout at the beginning */
438 *ppSurface
= (LPDIRECTDRAWSURFACE
)COM_INTERFACE_CAST(IDirectDrawSurfaceImpl
,
439 IDirectDrawSurface7
, IDirectDrawSurface3
,
442 impl
= ICOM_OBJECT(IDirectDrawSurfaceImpl
, IDirectDrawSurface7
, pSurface7
);
443 if(SUCCEEDED(hr
) && impl
)
446 IDirectDraw7_Release(COM_INTERFACE_CAST(IDirectDrawImpl
,
450 impl
->ifaceToRelease
= NULL
;
456 static HRESULT WINAPI
457 IDirectDraw3Impl_CreateSurface(LPDIRECTDRAW3 This
, LPDDSURFACEDESC pSDesc
,
458 LPDIRECTDRAWSURFACE
*ppSurface
,
461 LPDIRECTDRAWSURFACE7 pSurface7
;
462 IDirectDrawSurfaceImpl
*impl
;
465 hr
= IDirectDraw7_CreateSurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
469 (LPDDSURFACEDESC2
)pSDesc
, &pSurface7
, pUnkOuter
);
471 /* This coercion is safe, since the IDirectDrawSurface3 vtable has the
472 * IDirectDrawSurface vtable layout at the beginning */
473 *ppSurface
= (LPDIRECTDRAWSURFACE
)COM_INTERFACE_CAST(IDirectDrawSurfaceImpl
,
474 IDirectDrawSurface7
, IDirectDrawSurface3
,
477 impl
= ICOM_OBJECT(IDirectDrawSurfaceImpl
, IDirectDrawSurface7
, pSurface7
);
478 if(SUCCEEDED(hr
) && impl
)
481 IDirectDraw7_Release(COM_INTERFACE_CAST(IDirectDrawImpl
,
485 IDirectDraw3_AddRef(This
);
486 impl
->ifaceToRelease
= (IUnknown
*) This
;
492 static HRESULT WINAPI
493 IDirectDraw4Impl_CreateSurface(LPDIRECTDRAW4 This
, LPDDSURFACEDESC2 pSDesc
,
494 LPDIRECTDRAWSURFACE4
*ppSurface
,
498 IDirectDrawSurfaceImpl
*impl
;
500 hr
= IDirectDraw7_CreateSurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
505 (LPDIRECTDRAWSURFACE7
*)ppSurface
,
507 impl
= ICOM_OBJECT(IDirectDrawSurfaceImpl
, IDirectDrawSurface7
, *ppSurface
);
508 if(SUCCEEDED(hr
) && impl
)
511 IDirectDraw7_Release(COM_INTERFACE_CAST(IDirectDrawImpl
,
515 IDirectDraw4_AddRef(This
);
516 impl
->ifaceToRelease
= (IUnknown
*) This
;
521 static HRESULT WINAPI
522 IDirectDrawImpl_DuplicateSurface(LPDIRECTDRAW This
, LPDIRECTDRAWSURFACE pSrc
,
523 LPDIRECTDRAWSURFACE
*ppDst
)
525 LPDIRECTDRAWSURFACE7 pDst7
;
528 hr
= IDirectDraw7_DuplicateSurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
531 COM_INTERFACE_CAST(IDirectDrawSurfaceImpl
,
537 /* This coercion is safe, since the IDirectDrawSurface3 vtable has the
538 * IDirectDrawSurface vtable layout at the beginning */
539 *ppDst
= (LPDIRECTDRAWSURFACE
)COM_INTERFACE_CAST(IDirectDrawSurfaceImpl
, IDirectDrawSurface7
,
540 IDirectDrawSurface3
, pDst7
);
545 static HRESULT WINAPI
546 IDirectDraw2Impl_DuplicateSurface(LPDIRECTDRAW2 This
, LPDIRECTDRAWSURFACE pSrc
,
547 LPDIRECTDRAWSURFACE
*ppDst
)
549 LPDIRECTDRAWSURFACE7 pDst7
;
552 hr
= IDirectDraw7_DuplicateSurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
555 COM_INTERFACE_CAST(IDirectDrawSurfaceImpl
,
561 /* This coercion is safe, since the IDirectDrawSurface3 vtable has the
562 * IDirectDrawSurface vtable layout at the beginning */
563 *ppDst
= (LPDIRECTDRAWSURFACE
)COM_INTERFACE_CAST(IDirectDrawSurfaceImpl
, IDirectDrawSurface7
,
564 IDirectDrawSurface3
, pDst7
);
569 static HRESULT WINAPI
570 IDirectDraw3Impl_DuplicateSurface(LPDIRECTDRAW3 This
, LPDIRECTDRAWSURFACE pSrc
,
571 LPDIRECTDRAWSURFACE
*ppDst
)
573 LPDIRECTDRAWSURFACE7 pDst7
;
576 hr
= IDirectDraw7_DuplicateSurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
579 COM_INTERFACE_CAST(IDirectDrawSurfaceImpl
,
585 /* This coercion is safe, since the IDirectDrawSurface3 vtable has the
586 * IDirectDrawSurface vtable layout at the beginning */
587 *ppDst
= (LPDIRECTDRAWSURFACE
)COM_INTERFACE_CAST(IDirectDrawSurfaceImpl
, IDirectDrawSurface7
,
588 IDirectDrawSurface3
, pDst7
);
593 static HRESULT WINAPI
594 IDirectDraw4Impl_DuplicateSurface(LPDIRECTDRAW4 This
,
595 LPDIRECTDRAWSURFACE4 pSrc
,
596 LPDIRECTDRAWSURFACE4
*ppDst
)
598 return IDirectDraw7_DuplicateSurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
602 (LPDIRECTDRAWSURFACE7
)pSrc
,
603 (LPDIRECTDRAWSURFACE7
*)ppDst
);
606 struct displaymodescallback_context
608 LPDDENUMMODESCALLBACK func
;
612 static HRESULT CALLBACK
613 EnumDisplayModesCallbackThunk(LPDDSURFACEDESC2 pDDSD2
, LPVOID context
)
616 struct displaymodescallback_context
*cbcontext
= context
;
618 memcpy(&DDSD
,pDDSD2
,sizeof(DDSD
));
619 DDSD
.dwSize
= sizeof(DDSD
);
621 return cbcontext
->func(&DDSD
, cbcontext
->context
);
624 static HRESULT WINAPI
625 IDirectDrawImpl_EnumDisplayModes(LPDIRECTDRAW This
, DWORD dwFlags
,
626 LPDDSURFACEDESC pDDSD
, LPVOID context
,
627 LPDDENUMMODESCALLBACK cb
)
629 struct displaymodescallback_context cbcontext
;
632 cbcontext
.context
= context
;
634 return IDirectDraw7_EnumDisplayModes(COM_INTERFACE_CAST(IDirectDrawImpl
,
638 dwFlags
, (LPDDSURFACEDESC2
)pDDSD
, &cbcontext
,
639 EnumDisplayModesCallbackThunk
);
642 static HRESULT WINAPI
643 IDirectDraw2Impl_EnumDisplayModes(LPDIRECTDRAW2 This
, DWORD dwFlags
,
644 LPDDSURFACEDESC pDDSD
, LPVOID context
,
645 LPDDENUMMODESCALLBACK cb
)
647 struct displaymodescallback_context cbcontext
;
650 cbcontext
.context
= context
;
652 return IDirectDraw7_EnumDisplayModes(COM_INTERFACE_CAST(IDirectDrawImpl
,
656 dwFlags
, (LPDDSURFACEDESC2
)pDDSD
, &cbcontext
,
657 EnumDisplayModesCallbackThunk
);
660 static HRESULT WINAPI
661 IDirectDraw3Impl_EnumDisplayModes(LPDIRECTDRAW3 This
, DWORD dwFlags
,
662 LPDDSURFACEDESC pDDSD
, LPVOID context
,
663 LPDDENUMMODESCALLBACK cb
)
665 struct displaymodescallback_context cbcontext
;
668 cbcontext
.context
= context
;
670 return IDirectDraw7_EnumDisplayModes(COM_INTERFACE_CAST(IDirectDrawImpl
,
674 dwFlags
, (LPDDSURFACEDESC2
)pDDSD
, &cbcontext
,
675 EnumDisplayModesCallbackThunk
);
678 static HRESULT WINAPI
679 IDirectDraw4Impl_EnumDisplayModes(LPDIRECTDRAW4 This
, DWORD dwFlags
,
680 LPDDSURFACEDESC2 pDDSD
, LPVOID context
,
681 LPDDENUMMODESCALLBACK2 cb
)
683 return IDirectDraw7_EnumDisplayModes(COM_INTERFACE_CAST(IDirectDrawImpl
,
687 dwFlags
, pDDSD
, context
, cb
);
690 struct surfacescallback_context
692 LPDDENUMSURFACESCALLBACK func
;
696 static HRESULT CALLBACK
697 EnumSurfacesCallbackThunk(LPDIRECTDRAWSURFACE7 pSurf
, LPDDSURFACEDESC2 pDDSD
,
700 struct surfacescallback_context
*cbcontext
= context
;
702 /* This coercion is safe, since the IDirectDrawSurface3 vtable has the
703 * IDirectDrawSurface vtable layout at the beginning */
704 return cbcontext
->func((LPDIRECTDRAWSURFACE
)
705 COM_INTERFACE_CAST(IDirectDrawSurfaceImpl
,
707 IDirectDrawSurface3
, pSurf
),
708 (LPDDSURFACEDESC
)pDDSD
, cbcontext
->context
);
711 static HRESULT WINAPI
712 IDirectDrawImpl_EnumSurfaces(LPDIRECTDRAW This
, DWORD dwFlags
,
713 LPDDSURFACEDESC pDDSD
, LPVOID context
,
714 LPDDENUMSURFACESCALLBACK cb
)
716 struct surfacescallback_context cbcontext
;
719 cbcontext
.context
= context
;
721 return IDirectDraw7_EnumSurfaces(COM_INTERFACE_CAST(IDirectDrawImpl
,
724 dwFlags
, (LPDDSURFACEDESC2
)pDDSD
,
725 &cbcontext
, EnumSurfacesCallbackThunk
);
728 static HRESULT WINAPI
729 IDirectDraw2Impl_EnumSurfaces(LPDIRECTDRAW2 This
, DWORD dwFlags
,
730 LPDDSURFACEDESC pDDSD
, LPVOID context
,
731 LPDDENUMSURFACESCALLBACK cb
)
733 struct surfacescallback_context cbcontext
;
736 cbcontext
.context
= context
;
738 return IDirectDraw7_EnumSurfaces(COM_INTERFACE_CAST(IDirectDrawImpl
,
741 dwFlags
, (LPDDSURFACEDESC2
)pDDSD
,
742 &cbcontext
, EnumSurfacesCallbackThunk
);
745 static HRESULT WINAPI
746 IDirectDraw3Impl_EnumSurfaces(LPDIRECTDRAW3 This
, DWORD dwFlags
,
747 LPDDSURFACEDESC pDDSD
, LPVOID context
,
748 LPDDENUMSURFACESCALLBACK cb
)
750 struct surfacescallback_context cbcontext
;
753 cbcontext
.context
= context
;
755 return IDirectDraw7_EnumSurfaces(COM_INTERFACE_CAST(IDirectDrawImpl
,
758 dwFlags
, (LPDDSURFACEDESC2
)pDDSD
,
759 &cbcontext
, EnumSurfacesCallbackThunk
);
762 static HRESULT WINAPI
763 IDirectDraw4Impl_EnumSurfaces(LPDIRECTDRAW4 This
, DWORD dwFlags
,
764 LPDDSURFACEDESC2 pDDSD
, LPVOID context
,
765 LPDDENUMSURFACESCALLBACK2 cb
)
767 return IDirectDraw7_EnumSurfaces(COM_INTERFACE_CAST(IDirectDrawImpl
,
770 dwFlags
, pDDSD
, context
,
771 (LPDDENUMSURFACESCALLBACK7
)cb
);
774 static HRESULT WINAPI
775 IDirectDrawImpl_FlipToGDISurface(LPDIRECTDRAW This
)
777 return IDirectDraw7_FlipToGDISurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
783 static HRESULT WINAPI
784 IDirectDraw2Impl_FlipToGDISurface(LPDIRECTDRAW2 This
)
786 return IDirectDraw7_FlipToGDISurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
792 static HRESULT WINAPI
793 IDirectDraw3Impl_FlipToGDISurface(LPDIRECTDRAW3 This
)
795 return IDirectDraw7_FlipToGDISurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
801 static HRESULT WINAPI
802 IDirectDraw4Impl_FlipToGDISurface(LPDIRECTDRAW4 This
)
804 return IDirectDraw7_FlipToGDISurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
810 static HRESULT WINAPI
811 IDirectDrawImpl_GetCaps(LPDIRECTDRAW This
, LPDDCAPS pDDC1
, LPDDCAPS pDDC2
)
813 return IDirectDraw7_GetCaps(COM_INTERFACE_CAST(IDirectDrawImpl
,
814 IDirectDraw
, IDirectDraw7
,
815 This
), pDDC1
, pDDC2
);
818 static HRESULT WINAPI
819 IDirectDraw2Impl_GetCaps(LPDIRECTDRAW2 This
, LPDDCAPS pDDC1
, LPDDCAPS pDDC2
)
821 return IDirectDraw7_GetCaps(COM_INTERFACE_CAST(IDirectDrawImpl
,
822 IDirectDraw2
, IDirectDraw7
,
823 This
), pDDC1
, pDDC2
);
826 static HRESULT WINAPI
827 IDirectDraw3Impl_GetCaps(LPDIRECTDRAW3 This
, LPDDCAPS pDDC1
, LPDDCAPS pDDC2
)
829 return IDirectDraw7_GetCaps(COM_INTERFACE_CAST(IDirectDrawImpl
,
830 IDirectDraw3
, IDirectDraw7
,
831 This
), pDDC1
, pDDC2
);
834 static HRESULT WINAPI
835 IDirectDraw4Impl_GetCaps(LPDIRECTDRAW4 This
, LPDDCAPS pDDC1
, LPDDCAPS pDDC2
)
837 return IDirectDraw7_GetCaps(COM_INTERFACE_CAST(IDirectDrawImpl
,
838 IDirectDraw4
, IDirectDraw7
,
839 This
), pDDC1
, pDDC2
);
842 static HRESULT WINAPI
843 IDirectDrawImpl_GetDisplayMode(LPDIRECTDRAW This
, LPDDSURFACEDESC pDDSD
)
845 return IDirectDraw7_GetDisplayMode(COM_INTERFACE_CAST(IDirectDrawImpl
,
848 (LPDDSURFACEDESC2
)pDDSD
);
851 static HRESULT WINAPI
852 IDirectDraw2Impl_GetDisplayMode(LPDIRECTDRAW2 This
, LPDDSURFACEDESC pDDSD
)
854 return IDirectDraw7_GetDisplayMode(COM_INTERFACE_CAST(IDirectDrawImpl
,
857 (LPDDSURFACEDESC2
)pDDSD
);
860 static HRESULT WINAPI
861 IDirectDraw3Impl_GetDisplayMode(LPDIRECTDRAW3 This
, LPDDSURFACEDESC pDDSD
)
863 return IDirectDraw7_GetDisplayMode(COM_INTERFACE_CAST(IDirectDrawImpl
,
866 (LPDDSURFACEDESC2
)pDDSD
);
869 static HRESULT WINAPI
870 IDirectDraw4Impl_GetDisplayMode(LPDIRECTDRAW4 This
, LPDDSURFACEDESC2 pDDSD
)
872 return IDirectDraw7_GetDisplayMode(COM_INTERFACE_CAST(IDirectDrawImpl
,
878 static HRESULT WINAPI
879 IDirectDrawImpl_GetFourCCCodes(LPDIRECTDRAW This
, LPDWORD lpNumCodes
,
882 return IDirectDraw7_GetFourCCCodes(COM_INTERFACE_CAST(IDirectDrawImpl
,
886 lpNumCodes
, lpCodes
);
889 static HRESULT WINAPI
890 IDirectDraw2Impl_GetFourCCCodes(LPDIRECTDRAW2 This
, LPDWORD lpNumCodes
,
893 return IDirectDraw7_GetFourCCCodes(COM_INTERFACE_CAST(IDirectDrawImpl
,
897 lpNumCodes
, lpCodes
);
900 static HRESULT WINAPI
901 IDirectDraw3Impl_GetFourCCCodes(LPDIRECTDRAW3 This
, LPDWORD lpNumCodes
,
904 return IDirectDraw7_GetFourCCCodes(COM_INTERFACE_CAST(IDirectDrawImpl
,
908 lpNumCodes
, lpCodes
);
911 static HRESULT WINAPI
912 IDirectDraw4Impl_GetFourCCCodes(LPDIRECTDRAW4 This
, LPDWORD lpNumCodes
,
915 return IDirectDraw7_GetFourCCCodes(COM_INTERFACE_CAST(IDirectDrawImpl
,
919 lpNumCodes
, lpCodes
);
922 static HRESULT WINAPI
923 IDirectDrawImpl_GetGDISurface(LPDIRECTDRAW This
, LPDIRECTDRAWSURFACE
*ppSurf
)
925 LPDIRECTDRAWSURFACE7 pSurf7
;
928 hr
= IDirectDraw7_GetGDISurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
933 /* This coercion is safe, since the IDirectDrawSurface3 vtable has the
934 * IDirectDrawSurface vtable layout at the beginning */
935 *ppSurf
= (LPDIRECTDRAWSURFACE
)COM_INTERFACE_CAST(IDirectDrawSurfaceImpl
, IDirectDrawSurface7
,
936 IDirectDrawSurface3
, pSurf7
);
941 static HRESULT WINAPI
942 IDirectDraw2Impl_GetGDISurface(LPDIRECTDRAW2 This
, LPDIRECTDRAWSURFACE
*ppSurf
)
944 LPDIRECTDRAWSURFACE7 pSurf7
;
947 hr
= IDirectDraw7_GetGDISurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
952 /* This coercion is safe, since the IDirectDrawSurface3 vtable has the
953 * IDirectDrawSurface vtable layout at the beginning */
954 *ppSurf
= (LPDIRECTDRAWSURFACE
)COM_INTERFACE_CAST(IDirectDrawSurfaceImpl
, IDirectDrawSurface7
,
955 IDirectDrawSurface3
, pSurf7
);
960 static HRESULT WINAPI
961 IDirectDraw3Impl_GetGDISurface(LPDIRECTDRAW3 This
, LPDIRECTDRAWSURFACE
*ppSurf
)
963 LPDIRECTDRAWSURFACE7 pSurf7
;
966 hr
= IDirectDraw7_GetGDISurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
971 /* This coercion is safe, since the IDirectDrawSurface3 vtable has the
972 * IDirectDrawSurface vtable layout at the beginning */
973 *ppSurf
= (LPDIRECTDRAWSURFACE
)COM_INTERFACE_CAST(IDirectDrawSurfaceImpl
, IDirectDrawSurface7
,
974 IDirectDrawSurface3
, pSurf7
);
979 static HRESULT WINAPI
980 IDirectDraw4Impl_GetGDISurface(LPDIRECTDRAW4 This
,
981 LPDIRECTDRAWSURFACE4
*ppSurf
)
983 return IDirectDraw7_GetGDISurface(COM_INTERFACE_CAST(IDirectDrawImpl
,
987 (LPDIRECTDRAWSURFACE7
*)ppSurf
);
990 static HRESULT WINAPI
991 IDirectDrawImpl_GetMonitorFrequency(LPDIRECTDRAW This
, LPDWORD pdwFreq
)
993 return IDirectDraw7_GetMonitorFrequency(COM_INTERFACE_CAST(IDirectDrawImpl
,
1000 static HRESULT WINAPI
1001 IDirectDraw2Impl_GetMonitorFrequency(LPDIRECTDRAW2 This
, LPDWORD pdwFreq
)
1003 return IDirectDraw7_GetMonitorFrequency(COM_INTERFACE_CAST(IDirectDrawImpl
,
1010 static HRESULT WINAPI
1011 IDirectDraw3Impl_GetMonitorFrequency(LPDIRECTDRAW3 This
, LPDWORD pdwFreq
)
1013 return IDirectDraw7_GetMonitorFrequency(COM_INTERFACE_CAST(IDirectDrawImpl
,
1020 static HRESULT WINAPI
1021 IDirectDraw4Impl_GetMonitorFrequency(LPDIRECTDRAW4 This
, LPDWORD pdwFreq
)
1023 return IDirectDraw7_GetMonitorFrequency(COM_INTERFACE_CAST(IDirectDrawImpl
,
1030 static HRESULT WINAPI
1031 IDirectDrawImpl_GetScanLine(LPDIRECTDRAW This
, LPDWORD pdwLine
)
1033 return IDirectDraw7_GetScanLine(COM_INTERFACE_CAST(IDirectDrawImpl
,
1039 static HRESULT WINAPI
1040 IDirectDraw2Impl_GetScanLine(LPDIRECTDRAW2 This
, LPDWORD pdwLine
)
1042 return IDirectDraw7_GetScanLine(COM_INTERFACE_CAST(IDirectDrawImpl
,
1048 static HRESULT WINAPI
1049 IDirectDraw3Impl_GetScanLine(LPDIRECTDRAW3 This
, LPDWORD pdwLine
)
1051 return IDirectDraw7_GetScanLine(COM_INTERFACE_CAST(IDirectDrawImpl
,
1057 static HRESULT WINAPI
1058 IDirectDraw4Impl_GetScanLine(LPDIRECTDRAW4 This
, LPDWORD pdwLine
)
1060 return IDirectDraw7_GetScanLine(COM_INTERFACE_CAST(IDirectDrawImpl
,
1066 static HRESULT WINAPI
1067 IDirectDrawImpl_GetVerticalBlankStatus(LPDIRECTDRAW This
, LPBOOL lpbIsInVB
)
1069 return IDirectDraw7_GetVerticalBlankStatus(COM_INTERFACE_CAST(IDirectDrawImpl
,
1076 static HRESULT WINAPI
1077 IDirectDraw2Impl_GetVerticalBlankStatus(LPDIRECTDRAW2 This
, LPBOOL lpbIsInVB
)
1079 return IDirectDraw7_GetVerticalBlankStatus(COM_INTERFACE_CAST(IDirectDrawImpl
,
1086 static HRESULT WINAPI
1087 IDirectDraw3Impl_GetVerticalBlankStatus(LPDIRECTDRAW3 This
, LPBOOL lpbIsInVB
)
1089 return IDirectDraw7_GetVerticalBlankStatus(COM_INTERFACE_CAST(IDirectDrawImpl
,
1096 static HRESULT WINAPI
1097 IDirectDraw4Impl_GetVerticalBlankStatus(LPDIRECTDRAW4 This
, LPBOOL lpbIsInVB
)
1099 return IDirectDraw7_GetVerticalBlankStatus(COM_INTERFACE_CAST(IDirectDrawImpl
,
1106 static HRESULT WINAPI
1107 IDirectDrawImpl_Initialize(LPDIRECTDRAW iface
, LPGUID pGUID
)
1109 ICOM_THIS_FROM(IDirectDrawImpl
, IDirectDraw
, iface
);
1112 ret_value
= IDirectDraw7_Initialize(ICOM_INTERFACE(This
, IDirectDraw7
), pGUID
);
1117 static HRESULT WINAPI
1118 IDirectDraw2Impl_Initialize(LPDIRECTDRAW2 iface
, LPGUID pGUID
)
1120 ICOM_THIS_FROM(IDirectDrawImpl
, IDirectDraw2
, iface
);
1123 ret_value
= IDirectDraw7_Initialize(ICOM_INTERFACE(This
, IDirectDraw7
), pGUID
);
1128 static HRESULT WINAPI
1129 IDirectDraw3Impl_Initialize(LPDIRECTDRAW3 iface
, LPGUID pGUID
)
1131 ICOM_THIS_FROM(IDirectDrawImpl
, IDirectDraw3
, iface
);
1134 ret_value
= IDirectDraw7_Initialize(ICOM_INTERFACE(This
, IDirectDraw7
), pGUID
);
1139 static HRESULT WINAPI
1140 IDirectDraw4Impl_Initialize(LPDIRECTDRAW4 iface
, LPGUID pGUID
)
1142 ICOM_THIS_FROM(IDirectDrawImpl
, IDirectDraw4
, iface
);
1145 ret_value
= IDirectDraw7_Initialize(ICOM_INTERFACE(This
, IDirectDraw7
), pGUID
);
1151 static HRESULT WINAPI
1152 IDirectDrawImpl_RestoreDisplayMode(LPDIRECTDRAW This
)
1154 return IDirectDraw7_RestoreDisplayMode(COM_INTERFACE_CAST(IDirectDrawImpl
,
1160 static HRESULT WINAPI
1161 IDirectDraw2Impl_RestoreDisplayMode(LPDIRECTDRAW2 This
)
1163 return IDirectDraw7_RestoreDisplayMode(COM_INTERFACE_CAST(IDirectDrawImpl
,
1169 static HRESULT WINAPI
1170 IDirectDraw3Impl_RestoreDisplayMode(LPDIRECTDRAW3 This
)
1172 return IDirectDraw7_RestoreDisplayMode(COM_INTERFACE_CAST(IDirectDrawImpl
,
1178 static HRESULT WINAPI
1179 IDirectDraw4Impl_RestoreDisplayMode(LPDIRECTDRAW4 This
)
1181 return IDirectDraw7_RestoreDisplayMode(COM_INTERFACE_CAST(IDirectDrawImpl
,
1187 static HRESULT WINAPI
1188 IDirectDrawImpl_SetCooperativeLevel(LPDIRECTDRAW This
, HWND hWnd
,
1191 return IDirectDraw7_SetCooperativeLevel(COM_INTERFACE_CAST(IDirectDrawImpl
,
1198 static HRESULT WINAPI
1199 IDirectDraw2Impl_SetCooperativeLevel(LPDIRECTDRAW2 This
, HWND hWnd
,
1202 return IDirectDraw7_SetCooperativeLevel(COM_INTERFACE_CAST(IDirectDrawImpl
,
1209 static HRESULT WINAPI
1210 IDirectDraw3Impl_SetCooperativeLevel(LPDIRECTDRAW3 This
, HWND hWnd
,
1213 return IDirectDraw7_SetCooperativeLevel(COM_INTERFACE_CAST(IDirectDrawImpl
,
1220 static HRESULT WINAPI
1221 IDirectDraw4Impl_SetCooperativeLevel(LPDIRECTDRAW4 This
, HWND hWnd
,
1224 return IDirectDraw7_SetCooperativeLevel(COM_INTERFACE_CAST(IDirectDrawImpl
,
1231 static HRESULT WINAPI
1232 IDirectDrawImpl_SetDisplayMode(LPDIRECTDRAW This
, DWORD a
, DWORD b
, DWORD c
)
1234 return IDirectDraw7_SetDisplayMode(COM_INTERFACE_CAST(IDirectDrawImpl
,
1241 static HRESULT WINAPI
1242 IDirectDraw2Impl_SetDisplayMode(LPDIRECTDRAW2 This
, DWORD a
, DWORD b
, DWORD c
,
1245 return IDirectDraw7_SetDisplayMode(COM_INTERFACE_CAST(IDirectDrawImpl
,
1252 static HRESULT WINAPI
1253 IDirectDraw3Impl_SetDisplayMode(LPDIRECTDRAW3 This
, DWORD a
, DWORD b
, DWORD c
,
1256 return IDirectDraw7_SetDisplayMode(COM_INTERFACE_CAST(IDirectDrawImpl
,
1263 static HRESULT WINAPI
1264 IDirectDraw4Impl_SetDisplayMode(LPDIRECTDRAW4 This
, DWORD a
, DWORD b
, DWORD c
,
1267 return IDirectDraw7_SetDisplayMode(COM_INTERFACE_CAST(IDirectDrawImpl
,
1274 static HRESULT WINAPI
1275 IDirectDrawImpl_WaitForVerticalBlank(LPDIRECTDRAW This
, DWORD dwFlags
,
1278 return IDirectDraw7_WaitForVerticalBlank(COM_INTERFACE_CAST(IDirectDrawImpl
,
1285 static HRESULT WINAPI
1286 IDirectDraw2Impl_WaitForVerticalBlank(LPDIRECTDRAW2 This
, DWORD dwFlags
,
1289 return IDirectDraw7_WaitForVerticalBlank(COM_INTERFACE_CAST(IDirectDrawImpl
,
1296 static HRESULT WINAPI
1297 IDirectDraw3Impl_WaitForVerticalBlank(LPDIRECTDRAW3 This
, DWORD dwFlags
,
1300 return IDirectDraw7_WaitForVerticalBlank(COM_INTERFACE_CAST(IDirectDrawImpl
,
1307 static HRESULT WINAPI
1308 IDirectDraw4Impl_WaitForVerticalBlank(LPDIRECTDRAW4 This
, DWORD dwFlags
,
1311 return IDirectDraw7_WaitForVerticalBlank(COM_INTERFACE_CAST(IDirectDrawImpl
,
1318 static HRESULT WINAPI
1319 IDirectDraw2Impl_GetAvailableVidMem(LPDIRECTDRAW2 This
, LPDDSCAPS pCaps
,
1320 LPDWORD pdwTotal
, LPDWORD pdwFree
)
1323 DDRAW_Convert_DDSCAPS_1_To_2(pCaps
, &Caps2
);
1325 return IDirectDraw7_GetAvailableVidMem(COM_INTERFACE_CAST(IDirectDrawImpl
,
1329 &Caps2
, pdwTotal
, pdwFree
);
1332 static HRESULT WINAPI
1333 IDirectDraw3Impl_GetAvailableVidMem(LPDIRECTDRAW3 This
, LPDDSCAPS pCaps
,
1334 LPDWORD pdwTotal
, LPDWORD pdwFree
)
1337 DDRAW_Convert_DDSCAPS_1_To_2(pCaps
, &Caps2
);
1339 return IDirectDraw7_GetAvailableVidMem(COM_INTERFACE_CAST(IDirectDrawImpl
,
1343 &Caps2
, pdwTotal
, pdwFree
);
1346 static HRESULT WINAPI
1347 IDirectDraw4Impl_GetAvailableVidMem(LPDIRECTDRAW4 This
, LPDDSCAPS2 pCaps
,
1348 LPDWORD pdwTotal
, LPDWORD pdwFree
)
1350 return IDirectDraw7_GetAvailableVidMem(COM_INTERFACE_CAST(IDirectDrawImpl
,
1354 pCaps
, pdwTotal
, pdwFree
);
1357 static HRESULT WINAPI
1358 IDirectDraw3Impl_GetSurfaceFromDC(LPDIRECTDRAW3 This
, HDC hDC
,
1359 LPDIRECTDRAWSURFACE
*pSurf
)
1361 return IDirectDraw7_GetSurfaceFromDC(COM_INTERFACE_CAST(IDirectDrawImpl
,
1365 hDC
, (LPDIRECTDRAWSURFACE7
*)pSurf
);
1368 static HRESULT WINAPI
1369 IDirectDraw4Impl_GetSurfaceFromDC(LPDIRECTDRAW4 This
, HDC hDC
,
1370 LPDIRECTDRAWSURFACE4
*pSurf
)
1372 return IDirectDraw7_GetSurfaceFromDC(COM_INTERFACE_CAST(IDirectDrawImpl
,
1376 hDC
, (LPDIRECTDRAWSURFACE7
*)pSurf
);
1379 static HRESULT WINAPI
1380 IDirectDraw4Impl_RestoreAllSurfaces(LPDIRECTDRAW4 This
)
1382 return IDirectDraw7_RestoreAllSurfaces(COM_INTERFACE_CAST(IDirectDrawImpl
,
1388 static HRESULT WINAPI
1389 IDirectDraw4Impl_TestCooperativeLevel(LPDIRECTDRAW4 This
)
1391 return IDirectDraw7_TestCooperativeLevel(COM_INTERFACE_CAST(IDirectDrawImpl
,
1397 static HRESULT WINAPI
1398 IDirectDraw4Impl_GetDeviceIdentifier(LPDIRECTDRAW4 This
,
1399 LPDDDEVICEIDENTIFIER pDDDI
, DWORD dwFlags
)
1401 DDDEVICEIDENTIFIER2 DDDI2
;
1404 hr
= IDirectDraw7_GetDeviceIdentifier(COM_INTERFACE_CAST(IDirectDrawImpl
,
1410 DDRAW_Convert_DDDEVICEIDENTIFIER_2_To_1(&DDDI2
, pDDDI
);
1415 const IDirectDrawVtbl IDirectDraw1_Vtbl
=
1417 IDirectDrawImpl_QueryInterface
,
1418 IDirectDrawImpl_AddRef
,
1419 IDirectDrawImpl_Release
,
1420 IDirectDrawImpl_Compact
,
1421 IDirectDrawImpl_CreateClipper
,
1422 IDirectDrawImpl_CreatePalette
,
1423 IDirectDrawImpl_CreateSurface
,
1424 IDirectDrawImpl_DuplicateSurface
,
1425 IDirectDrawImpl_EnumDisplayModes
,
1426 IDirectDrawImpl_EnumSurfaces
,
1427 IDirectDrawImpl_FlipToGDISurface
,
1428 IDirectDrawImpl_GetCaps
,
1429 IDirectDrawImpl_GetDisplayMode
,
1430 IDirectDrawImpl_GetFourCCCodes
,
1431 IDirectDrawImpl_GetGDISurface
,
1432 IDirectDrawImpl_GetMonitorFrequency
,
1433 IDirectDrawImpl_GetScanLine
,
1434 IDirectDrawImpl_GetVerticalBlankStatus
,
1435 IDirectDrawImpl_Initialize
,
1436 IDirectDrawImpl_RestoreDisplayMode
,
1437 IDirectDrawImpl_SetCooperativeLevel
,
1438 IDirectDrawImpl_SetDisplayMode
,
1439 IDirectDrawImpl_WaitForVerticalBlank
,
1442 const IDirectDraw2Vtbl IDirectDraw2_Vtbl
=
1444 IDirectDraw2Impl_QueryInterface
,
1445 IDirectDraw2Impl_AddRef
,
1446 IDirectDraw2Impl_Release
,
1447 IDirectDraw2Impl_Compact
,
1448 IDirectDraw2Impl_CreateClipper
,
1449 IDirectDraw2Impl_CreatePalette
,
1450 IDirectDraw2Impl_CreateSurface
,
1451 IDirectDraw2Impl_DuplicateSurface
,
1452 IDirectDraw2Impl_EnumDisplayModes
,
1453 IDirectDraw2Impl_EnumSurfaces
,
1454 IDirectDraw2Impl_FlipToGDISurface
,
1455 IDirectDraw2Impl_GetCaps
,
1456 IDirectDraw2Impl_GetDisplayMode
,
1457 IDirectDraw2Impl_GetFourCCCodes
,
1458 IDirectDraw2Impl_GetGDISurface
,
1459 IDirectDraw2Impl_GetMonitorFrequency
,
1460 IDirectDraw2Impl_GetScanLine
,
1461 IDirectDraw2Impl_GetVerticalBlankStatus
,
1462 IDirectDraw2Impl_Initialize
,
1463 IDirectDraw2Impl_RestoreDisplayMode
,
1464 IDirectDraw2Impl_SetCooperativeLevel
,
1465 IDirectDraw2Impl_SetDisplayMode
,
1466 IDirectDraw2Impl_WaitForVerticalBlank
,
1467 IDirectDraw2Impl_GetAvailableVidMem
1470 const IDirectDraw3Vtbl IDirectDraw3_Vtbl
=
1472 IDirectDraw3Impl_QueryInterface
,
1473 IDirectDraw3Impl_AddRef
,
1474 IDirectDraw3Impl_Release
,
1475 IDirectDraw3Impl_Compact
,
1476 IDirectDraw3Impl_CreateClipper
,
1477 IDirectDraw3Impl_CreatePalette
,
1478 IDirectDraw3Impl_CreateSurface
,
1479 IDirectDraw3Impl_DuplicateSurface
,
1480 IDirectDraw3Impl_EnumDisplayModes
,
1481 IDirectDraw3Impl_EnumSurfaces
,
1482 IDirectDraw3Impl_FlipToGDISurface
,
1483 IDirectDraw3Impl_GetCaps
,
1484 IDirectDraw3Impl_GetDisplayMode
,
1485 IDirectDraw3Impl_GetFourCCCodes
,
1486 IDirectDraw3Impl_GetGDISurface
,
1487 IDirectDraw3Impl_GetMonitorFrequency
,
1488 IDirectDraw3Impl_GetScanLine
,
1489 IDirectDraw3Impl_GetVerticalBlankStatus
,
1490 IDirectDraw3Impl_Initialize
,
1491 IDirectDraw3Impl_RestoreDisplayMode
,
1492 IDirectDraw3Impl_SetCooperativeLevel
,
1493 IDirectDraw3Impl_SetDisplayMode
,
1494 IDirectDraw3Impl_WaitForVerticalBlank
,
1495 IDirectDraw3Impl_GetAvailableVidMem
,
1496 IDirectDraw3Impl_GetSurfaceFromDC
,
1499 const IDirectDraw4Vtbl IDirectDraw4_Vtbl
=
1501 IDirectDraw4Impl_QueryInterface
,
1502 IDirectDraw4Impl_AddRef
,
1503 IDirectDraw4Impl_Release
,
1504 IDirectDraw4Impl_Compact
,
1505 IDirectDraw4Impl_CreateClipper
,
1506 IDirectDraw4Impl_CreatePalette
,
1507 IDirectDraw4Impl_CreateSurface
,
1508 IDirectDraw4Impl_DuplicateSurface
,
1509 IDirectDraw4Impl_EnumDisplayModes
,
1510 IDirectDraw4Impl_EnumSurfaces
,
1511 IDirectDraw4Impl_FlipToGDISurface
,
1512 IDirectDraw4Impl_GetCaps
,
1513 IDirectDraw4Impl_GetDisplayMode
,
1514 IDirectDraw4Impl_GetFourCCCodes
,
1515 IDirectDraw4Impl_GetGDISurface
,
1516 IDirectDraw4Impl_GetMonitorFrequency
,
1517 IDirectDraw4Impl_GetScanLine
,
1518 IDirectDraw4Impl_GetVerticalBlankStatus
,
1519 IDirectDraw4Impl_Initialize
,
1520 IDirectDraw4Impl_RestoreDisplayMode
,
1521 IDirectDraw4Impl_SetCooperativeLevel
,
1522 IDirectDraw4Impl_SetDisplayMode
,
1523 IDirectDraw4Impl_WaitForVerticalBlank
,
1524 IDirectDraw4Impl_GetAvailableVidMem
,
1525 IDirectDraw4Impl_GetSurfaceFromDC
,
1526 IDirectDraw4Impl_RestoreAllSurfaces
,
1527 IDirectDraw4Impl_TestCooperativeLevel
,
1528 IDirectDraw4Impl_GetDeviceIdentifier