1 /*==========================================================================;
2  *
3  *  Copyright (C) Microsoft Corporation.  All Rights Reserved.
4  *
5  *  File:   d3d8.h
6  *  Content:    Direct3D include file
7  *
8  ****************************************************************************/
9 
10 #ifndef _D3D8_H_
11 #define _D3D8_H_
12 
13 #ifndef DIRECT3D_VERSION
14 #define DIRECT3D_VERSION         0x0800
15 #endif
16 
17 /* include this file content only if compiling for DX8 interfaces */
18 #if(DIRECT3D_VERSION >= 0x0800)
19 
20 /* This identifier is passed to Direct3DCreate8 in order to ensure that an
21  * application was built against the correct header files. This number is
22  * incremented whenever a header (or other) change would require applications
23  * to be rebuilt. If the version doesn't match, Direct3DCreate8 will fail.
24  * (The number itself has no meaning.)*/
25 
26 #define D3D_SDK_VERSION 220
27 
28 #include <stdlib.h>
29 
30 #define COM_NO_WINDOWS_H
31 #include <objbase.h>
32 
33 #include <windows.h>
34 
35 #if !defined(HMONITOR_DECLARED) && (WINVER < 0x0500)
36     #define HMONITOR_DECLARED
37     DECLARE_HANDLE(HMONITOR);
38 #endif
39 
40 #define D3DAPI WINAPI
41 
42 /*
43  * Interface IID's
44  */
45 #if defined( _WIN32 ) && !defined( _NO_COM)
46 
47 /* IID_IDirect3D8 */
48 /* {1DD9E8DA-1C77-4d40-B0CF-98FEFDFF9512} */
49 DEFINE_GUID(IID_IDirect3D8, 0x1dd9e8da, 0x1c77, 0x4d40, 0xb0, 0xcf, 0x98, 0xfe, 0xfd, 0xff, 0x95, 0x12);
50 
51 /* IID_IDirect3DDevice8 */
52 /* {7385E5DF-8FE8-41D5-86B6-D7B48547B6CF} */
53 DEFINE_GUID(IID_IDirect3DDevice8, 0x7385e5df, 0x8fe8, 0x41d5, 0x86, 0xb6, 0xd7, 0xb4, 0x85, 0x47, 0xb6, 0xcf);
54 
55 /* IID_IDirect3DResource8 */
56 /* {1B36BB7B-09B7-410a-B445-7D1430D7B33F} */
57 DEFINE_GUID(IID_IDirect3DResource8, 0x1b36bb7b, 0x9b7, 0x410a, 0xb4, 0x45, 0x7d, 0x14, 0x30, 0xd7, 0xb3, 0x3f);
58 
59 /* IID_IDirect3DBaseTexture8 */
60 /* {B4211CFA-51B9-4a9f-AB78-DB99B2BB678E} */
61 DEFINE_GUID(IID_IDirect3DBaseTexture8, 0xb4211cfa, 0x51b9, 0x4a9f, 0xab, 0x78, 0xdb, 0x99, 0xb2, 0xbb, 0x67, 0x8e);
62 
63 /* IID_IDirect3DTexture8 */
64 /* {E4CDD575-2866-4f01-B12E-7EECE1EC9358} */
65 DEFINE_GUID(IID_IDirect3DTexture8, 0xe4cdd575, 0x2866, 0x4f01, 0xb1, 0x2e, 0x7e, 0xec, 0xe1, 0xec, 0x93, 0x58);
66 
67 /* IID_IDirect3DCubeTexture8 */
68 /* {3EE5B968-2ACA-4c34-8BB5-7E0C3D19B750} */
69 DEFINE_GUID(IID_IDirect3DCubeTexture8, 0x3ee5b968, 0x2aca, 0x4c34, 0x8b, 0xb5, 0x7e, 0x0c, 0x3d, 0x19, 0xb7, 0x50);
70 
71 /* IID_IDirect3DVolumeTexture8 */
72 /* {4B8AAAFA-140F-42ba-9131-597EAFAA2EAD} */
73 DEFINE_GUID(IID_IDirect3DVolumeTexture8, 0x4b8aaafa, 0x140f, 0x42ba, 0x91, 0x31, 0x59, 0x7e, 0xaf, 0xaa, 0x2e, 0xad);
74 
75 /* IID_IDirect3DVertexBuffer8 */
76 /* {8AEEEAC7-05F9-44d4-B591-000B0DF1CB95} */
77 DEFINE_GUID(IID_IDirect3DVertexBuffer8, 0x8aeeeac7, 0x05f9, 0x44d4, 0xb5, 0x91, 0x00, 0x0b, 0x0d, 0xf1, 0xcb, 0x95);
78 
79 /* IID_IDirect3DIndexBuffer8 */
80 /* {0E689C9A-053D-44a0-9D92-DB0E3D750F86} */
81 DEFINE_GUID(IID_IDirect3DIndexBuffer8, 0x0e689c9a, 0x053d, 0x44a0, 0x9d, 0x92, 0xdb, 0x0e, 0x3d, 0x75, 0x0f, 0x86);
82 
83 /* IID_IDirect3DSurface8 */
84 /* {B96EEBCA-B326-4ea5-882F-2FF5BAE021DD} */
85 DEFINE_GUID(IID_IDirect3DSurface8, 0xb96eebca, 0xb326, 0x4ea5, 0x88, 0x2f, 0x2f, 0xf5, 0xba, 0xe0, 0x21, 0xdd);
86 
87 /* IID_IDirect3DVolume8 */
88 /* {BD7349F5-14F1-42e4-9C79-972380DB40C0} */
89 DEFINE_GUID(IID_IDirect3DVolume8, 0xbd7349f5, 0x14f1, 0x42e4, 0x9c, 0x79, 0x97, 0x23, 0x80, 0xdb, 0x40, 0xc0);
90 
91 /* IID_IDirect3DSwapChain8 */
92 /* {928C088B-76B9-4C6B-A536-A590853876CD} */
93 DEFINE_GUID(IID_IDirect3DSwapChain8, 0x928c088b, 0x76b9, 0x4c6b, 0xa5, 0x36, 0xa5, 0x90, 0x85, 0x38, 0x76, 0xcd);
94 
95 #endif
96 
97 #ifdef __cplusplus
98 
99 interface IDirect3D8;
100 interface IDirect3DDevice8;
101 
102 interface IDirect3DResource8;
103 interface IDirect3DBaseTexture8;
104 interface IDirect3DTexture8;
105 interface IDirect3DVolumeTexture8;
106 interface IDirect3DCubeTexture8;
107 
108 interface IDirect3DVertexBuffer8;
109 interface IDirect3DIndexBuffer8;
110 
111 interface IDirect3DSurface8;
112 interface IDirect3DVolume8;
113 
114 interface IDirect3DSwapChain8;
115 
116 #endif
117 
118 typedef interface IDirect3D8                IDirect3D8;
119 typedef interface IDirect3DDevice8          IDirect3DDevice8;
120 typedef interface IDirect3DResource8        IDirect3DResource8;
121 typedef interface IDirect3DBaseTexture8     IDirect3DBaseTexture8;
122 typedef interface IDirect3DTexture8         IDirect3DTexture8;
123 typedef interface IDirect3DVolumeTexture8   IDirect3DVolumeTexture8;
124 typedef interface IDirect3DCubeTexture8     IDirect3DCubeTexture8;
125 typedef interface IDirect3DVertexBuffer8    IDirect3DVertexBuffer8;
126 typedef interface IDirect3DIndexBuffer8     IDirect3DIndexBuffer8;
127 typedef interface IDirect3DSurface8         IDirect3DSurface8;
128 typedef interface IDirect3DVolume8          IDirect3DVolume8;
129 typedef interface IDirect3DSwapChain8       IDirect3DSwapChain8;
130 
131 #include "d3d8types.h"
132 #include "d3d8caps.h"
133 
134 #ifdef __cplusplus
135 extern "C" {
136 #endif
137 
138 /*
139  * DLL Function for creating a Direct3D8 object. This object supports
140  * enumeration and allows the creation of Direct3DDevice8 objects.
141  * Pass the value of the constant D3D_SDK_VERSION to this function, so
142  * that the run-time can validate that your application was compiled
143  * against the right headers.
144  */
145 
146 IDirect3D8 * WINAPI Direct3DCreate8(UINT SDKVersion);
147 
148 /*
149  * Direct3D interfaces
150  */
151 
152 #undef INTERFACE
153 #define INTERFACE IDirect3D8
154 
DECLARE_INTERFACE_(IDirect3D8,IUnknown)155 DECLARE_INTERFACE_(IDirect3D8, IUnknown)
156 {
157     /*** IUnknown methods ***/
158     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
159     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
160     STDMETHOD_(ULONG,Release)(THIS) PURE;
161 
162     /*** IDirect3D8 methods ***/
163     STDMETHOD(RegisterSoftwareDevice)(THIS_ void* pInitializeFunction) PURE;
164     STDMETHOD_(UINT, GetAdapterCount)(THIS) PURE;
165     STDMETHOD(GetAdapterIdentifier)(THIS_ UINT Adapter,DWORD Flags,D3DADAPTER_IDENTIFIER8* pIdentifier) PURE;
166     STDMETHOD_(UINT, GetAdapterModeCount)(THIS_ UINT Adapter) PURE;
167     STDMETHOD(EnumAdapterModes)(THIS_ UINT Adapter,UINT Mode,D3DDISPLAYMODE* pMode) PURE;
168     STDMETHOD(GetAdapterDisplayMode)(THIS_ UINT Adapter,D3DDISPLAYMODE* pMode) PURE;
169     STDMETHOD(CheckDeviceType)(THIS_ UINT Adapter,D3DDEVTYPE CheckType,D3DFORMAT DisplayFormat,D3DFORMAT BackBufferFormat,BOOL Windowed) PURE;
170     STDMETHOD(CheckDeviceFormat)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT AdapterFormat,DWORD Usage,D3DRESOURCETYPE RType,D3DFORMAT CheckFormat) PURE;
171     STDMETHOD(CheckDeviceMultiSampleType)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT SurfaceFormat,BOOL Windowed,D3DMULTISAMPLE_TYPE MultiSampleType) PURE;
172     STDMETHOD(CheckDepthStencilMatch)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT AdapterFormat,D3DFORMAT RenderTargetFormat,D3DFORMAT DepthStencilFormat) PURE;
173     STDMETHOD(GetDeviceCaps)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DCAPS8* pCaps) PURE;
174     STDMETHOD_(HMONITOR, GetAdapterMonitor)(THIS_ UINT Adapter) PURE;
175     STDMETHOD(CreateDevice)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,HWND hFocusWindow,DWORD BehaviorFlags,D3DPRESENT_PARAMETERS* pPresentationParameters,IDirect3DDevice8** ppReturnedDeviceInterface) PURE;
176 };
177 
178 typedef struct IDirect3D8 *LPDIRECT3D8, *PDIRECT3D8;
179 
180 #if !defined(__cplusplus) || defined(CINTERFACE)
181 #define IDirect3D8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
182 #define IDirect3D8_AddRef(p) (p)->lpVtbl->AddRef(p)
183 #define IDirect3D8_Release(p) (p)->lpVtbl->Release(p)
184 #define IDirect3D8_RegisterSoftwareDevice(p,a) (p)->lpVtbl->RegisterSoftwareDevice(p,a)
185 #define IDirect3D8_GetAdapterCount(p) (p)->lpVtbl->GetAdapterCount(p)
186 #define IDirect3D8_GetAdapterIdentifier(p,a,b,c) (p)->lpVtbl->GetAdapterIdentifier(p,a,b,c)
187 #define IDirect3D8_GetAdapterModeCount(p,a) (p)->lpVtbl->GetAdapterModeCount(p,a)
188 #define IDirect3D8_EnumAdapterModes(p,a,b,c) (p)->lpVtbl->EnumAdapterModes(p,a,b,c)
189 #define IDirect3D8_GetAdapterDisplayMode(p,a,b) (p)->lpVtbl->GetAdapterDisplayMode(p,a,b)
190 #define IDirect3D8_CheckDeviceType(p,a,b,c,d,e) (p)->lpVtbl->CheckDeviceType(p,a,b,c,d,e)
191 #define IDirect3D8_CheckDeviceFormat(p,a,b,c,d,e,f) (p)->lpVtbl->CheckDeviceFormat(p,a,b,c,d,e,f)
192 #define IDirect3D8_CheckDeviceMultiSampleType(p,a,b,c,d,e) (p)->lpVtbl->CheckDeviceMultiSampleType(p,a,b,c,d,e)
193 #define IDirect3D8_CheckDepthStencilMatch(p,a,b,c,d,e) (p)->lpVtbl->CheckDepthStencilMatch(p,a,b,c,d,e)
194 #define IDirect3D8_GetDeviceCaps(p,a,b,c) (p)->lpVtbl->GetDeviceCaps(p,a,b,c)
195 #define IDirect3D8_GetAdapterMonitor(p,a) (p)->lpVtbl->GetAdapterMonitor(p,a)
196 #define IDirect3D8_CreateDevice(p,a,b,c,d,e,f) (p)->lpVtbl->CreateDevice(p,a,b,c,d,e,f)
197 #else
198 #define IDirect3D8_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
199 #define IDirect3D8_AddRef(p) (p)->AddRef()
200 #define IDirect3D8_Release(p) (p)->Release()
201 #define IDirect3D8_RegisterSoftwareDevice(p,a) (p)->RegisterSoftwareDevice(a)
202 #define IDirect3D8_GetAdapterCount(p) (p)->GetAdapterCount()
203 #define IDirect3D8_GetAdapterIdentifier(p,a,b,c) (p)->GetAdapterIdentifier(a,b,c)
204 #define IDirect3D8_GetAdapterModeCount(p,a) (p)->GetAdapterModeCount(a)
205 #define IDirect3D8_EnumAdapterModes(p,a,b,c) (p)->EnumAdapterModes(a,b,c)
206 #define IDirect3D8_GetAdapterDisplayMode(p,a,b) (p)->GetAdapterDisplayMode(a,b)
207 #define IDirect3D8_CheckDeviceType(p,a,b,c,d,e) (p)->CheckDeviceType(a,b,c,d,e)
208 #define IDirect3D8_CheckDeviceFormat(p,a,b,c,d,e,f) (p)->CheckDeviceFormat(a,b,c,d,e,f)
209 #define IDirect3D8_CheckDeviceMultiSampleType(p,a,b,c,d,e) (p)->CheckDeviceMultiSampleType(a,b,c,d,e)
210 #define IDirect3D8_CheckDepthStencilMatch(p,a,b,c,d,e) (p)->CheckDepthStencilMatch(a,b,c,d,e)
211 #define IDirect3D8_GetDeviceCaps(p,a,b,c) (p)->GetDeviceCaps(a,b,c)
212 #define IDirect3D8_GetAdapterMonitor(p,a) (p)->GetAdapterMonitor(a)
213 #define IDirect3D8_CreateDevice(p,a,b,c,d,e,f) (p)->CreateDevice(a,b,c,d,e,f)
214 #endif
215 
216 #undef INTERFACE
217 #define INTERFACE IDirect3DDevice8
218 
DECLARE_INTERFACE_(IDirect3DDevice8,IUnknown)219 DECLARE_INTERFACE_(IDirect3DDevice8, IUnknown)
220 {
221     /*** IUnknown methods ***/
222     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
223     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
224     STDMETHOD_(ULONG,Release)(THIS) PURE;
225 
226     /*** IDirect3DDevice8 methods ***/
227     STDMETHOD(TestCooperativeLevel)(THIS) PURE;
228     STDMETHOD_(UINT, GetAvailableTextureMem)(THIS) PURE;
229     STDMETHOD(ResourceManagerDiscardBytes)(THIS_ DWORD Bytes) PURE;
230     STDMETHOD(GetDirect3D)(THIS_ IDirect3D8** ppD3D8) PURE;
231     STDMETHOD(GetDeviceCaps)(THIS_ D3DCAPS8* pCaps) PURE;
232     STDMETHOD(GetDisplayMode)(THIS_ D3DDISPLAYMODE* pMode) PURE;
233     STDMETHOD(GetCreationParameters)(THIS_ D3DDEVICE_CREATION_PARAMETERS *pParameters) PURE;
234     STDMETHOD(SetCursorProperties)(THIS_ UINT XHotSpot,UINT YHotSpot,IDirect3DSurface8* pCursorBitmap) PURE;
235     STDMETHOD_(void, SetCursorPosition)(THIS_ int X,int Y,DWORD Flags) PURE;
236     STDMETHOD_(BOOL, ShowCursor)(THIS_ BOOL bShow) PURE;
237     STDMETHOD(CreateAdditionalSwapChain)(THIS_ D3DPRESENT_PARAMETERS* pPresentationParameters,IDirect3DSwapChain8** pSwapChain) PURE;
238     STDMETHOD(Reset)(THIS_ D3DPRESENT_PARAMETERS* pPresentationParameters) PURE;
239     STDMETHOD(Present)(THIS_ CONST RECT* pSourceRect,CONST RECT* pDestRect,HWND hDestWindowOverride,CONST RGNDATA* pDirtyRegion) PURE;
240     STDMETHOD(GetBackBuffer)(THIS_ UINT BackBuffer,D3DBACKBUFFER_TYPE Type,IDirect3DSurface8** ppBackBuffer) PURE;
241     STDMETHOD(GetRasterStatus)(THIS_ D3DRASTER_STATUS* pRasterStatus) PURE;
242     STDMETHOD_(void, SetGammaRamp)(THIS_ DWORD Flags,CONST D3DGAMMARAMP* pRamp) PURE;
243     STDMETHOD_(void, GetGammaRamp)(THIS_ D3DGAMMARAMP* pRamp) PURE;
244     STDMETHOD(CreateTexture)(THIS_ UINT Width,UINT Height,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DTexture8** ppTexture) PURE;
245     STDMETHOD(CreateVolumeTexture)(THIS_ UINT Width,UINT Height,UINT Depth,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DVolumeTexture8** ppVolumeTexture) PURE;
246     STDMETHOD(CreateCubeTexture)(THIS_ UINT EdgeLength,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DCubeTexture8** ppCubeTexture) PURE;
247     STDMETHOD(CreateVertexBuffer)(THIS_ UINT Length,DWORD Usage,DWORD FVF,D3DPOOL Pool,IDirect3DVertexBuffer8** ppVertexBuffer) PURE;
248     STDMETHOD(CreateIndexBuffer)(THIS_ UINT Length,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DIndexBuffer8** ppIndexBuffer) PURE;
249     STDMETHOD(CreateRenderTarget)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DMULTISAMPLE_TYPE MultiSample,BOOL Lockable,IDirect3DSurface8** ppSurface) PURE;
250     STDMETHOD(CreateDepthStencilSurface)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DMULTISAMPLE_TYPE MultiSample,IDirect3DSurface8** ppSurface) PURE;
251     STDMETHOD(CreateImageSurface)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,IDirect3DSurface8** ppSurface) PURE;
252     STDMETHOD(CopyRects)(THIS_ IDirect3DSurface8* pSourceSurface,CONST RECT* pSourceRectsArray,UINT cRects,IDirect3DSurface8* pDestinationSurface,CONST POINT* pDestPointsArray) PURE;
253     STDMETHOD(UpdateTexture)(THIS_ IDirect3DBaseTexture8* pSourceTexture,IDirect3DBaseTexture8* pDestinationTexture) PURE;
254     STDMETHOD(GetFrontBuffer)(THIS_ IDirect3DSurface8* pDestSurface) PURE;
255     STDMETHOD(SetRenderTarget)(THIS_ IDirect3DSurface8* pRenderTarget,IDirect3DSurface8* pNewZStencil) PURE;
256     STDMETHOD(GetRenderTarget)(THIS_ IDirect3DSurface8** ppRenderTarget) PURE;
257     STDMETHOD(GetDepthStencilSurface)(THIS_ IDirect3DSurface8** ppZStencilSurface) PURE;
258     STDMETHOD(BeginScene)(THIS) PURE;
259     STDMETHOD(EndScene)(THIS) PURE;
260     STDMETHOD(Clear)(THIS_ DWORD Count,CONST D3DRECT* pRects,DWORD Flags,D3DCOLOR Color,float Z,DWORD Stencil) PURE;
261     STDMETHOD(SetTransform)(THIS_ D3DTRANSFORMSTATETYPE State,CONST D3DMATRIX* pMatrix) PURE;
262     STDMETHOD(GetTransform)(THIS_ D3DTRANSFORMSTATETYPE State,D3DMATRIX* pMatrix) PURE;
263     STDMETHOD(MultiplyTransform)(THIS_ D3DTRANSFORMSTATETYPE,CONST D3DMATRIX*) PURE;
264     STDMETHOD(SetViewport)(THIS_ CONST D3DVIEWPORT8* pViewport) PURE;
265     STDMETHOD(GetViewport)(THIS_ D3DVIEWPORT8* pViewport) PURE;
266     STDMETHOD(SetMaterial)(THIS_ CONST D3DMATERIAL8* pMaterial) PURE;
267     STDMETHOD(GetMaterial)(THIS_ D3DMATERIAL8* pMaterial) PURE;
268     STDMETHOD(SetLight)(THIS_ DWORD Index,CONST D3DLIGHT8*) PURE;
269     STDMETHOD(GetLight)(THIS_ DWORD Index,D3DLIGHT8*) PURE;
270     STDMETHOD(LightEnable)(THIS_ DWORD Index,BOOL Enable) PURE;
271     STDMETHOD(GetLightEnable)(THIS_ DWORD Index,BOOL* pEnable) PURE;
272     STDMETHOD(SetClipPlane)(THIS_ DWORD Index,CONST float* pPlane) PURE;
273     STDMETHOD(GetClipPlane)(THIS_ DWORD Index,float* pPlane) PURE;
274     STDMETHOD(SetRenderState)(THIS_ D3DRENDERSTATETYPE State,DWORD Value) PURE;
275     STDMETHOD(GetRenderState)(THIS_ D3DRENDERSTATETYPE State,DWORD* pValue) PURE;
276     STDMETHOD(BeginStateBlock)(THIS) PURE;
277     STDMETHOD(EndStateBlock)(THIS_ DWORD* pToken) PURE;
278     STDMETHOD(ApplyStateBlock)(THIS_ DWORD Token) PURE;
279     STDMETHOD(CaptureStateBlock)(THIS_ DWORD Token) PURE;
280     STDMETHOD(DeleteStateBlock)(THIS_ DWORD Token) PURE;
281     STDMETHOD(CreateStateBlock)(THIS_ D3DSTATEBLOCKTYPE Type,DWORD* pToken) PURE;
282     STDMETHOD(SetClipStatus)(THIS_ CONST D3DCLIPSTATUS8* pClipStatus) PURE;
283     STDMETHOD(GetClipStatus)(THIS_ D3DCLIPSTATUS8* pClipStatus) PURE;
284     STDMETHOD(GetTexture)(THIS_ DWORD Stage,IDirect3DBaseTexture8** ppTexture) PURE;
285     STDMETHOD(SetTexture)(THIS_ DWORD Stage,IDirect3DBaseTexture8* pTexture) PURE;
286     STDMETHOD(GetTextureStageState)(THIS_ DWORD Stage,D3DTEXTURESTAGESTATETYPE Type,DWORD* pValue) PURE;
287     STDMETHOD(SetTextureStageState)(THIS_ DWORD Stage,D3DTEXTURESTAGESTATETYPE Type,DWORD Value) PURE;
288     STDMETHOD(ValidateDevice)(THIS_ DWORD* pNumPasses) PURE;
289     STDMETHOD(GetInfo)(THIS_ DWORD DevInfoID,void* pDevInfoStruct,DWORD DevInfoStructSize) PURE;
290     STDMETHOD(SetPaletteEntries)(THIS_ UINT PaletteNumber,CONST PALETTEENTRY* pEntries) PURE;
291     STDMETHOD(GetPaletteEntries)(THIS_ UINT PaletteNumber,PALETTEENTRY* pEntries) PURE;
292     STDMETHOD(SetCurrentTexturePalette)(THIS_ UINT PaletteNumber) PURE;
293     STDMETHOD(GetCurrentTexturePalette)(THIS_ UINT *PaletteNumber) PURE;
294     STDMETHOD(DrawPrimitive)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT StartVertex,UINT PrimitiveCount) PURE;
295     STDMETHOD(DrawIndexedPrimitive)(THIS_ D3DPRIMITIVETYPE,UINT minIndex,UINT NumVertices,UINT startIndex,UINT primCount) PURE;
296     STDMETHOD(DrawPrimitiveUP)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT PrimitiveCount,CONST void* pVertexStreamZeroData,UINT VertexStreamZeroStride) PURE;
297     STDMETHOD(DrawIndexedPrimitiveUP)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT MinVertexIndex,UINT NumVertexIndices,UINT PrimitiveCount,CONST void* pIndexData,D3DFORMAT IndexDataFormat,CONST void* pVertexStreamZeroData,UINT VertexStreamZeroStride) PURE;
298     STDMETHOD(ProcessVertices)(THIS_ UINT SrcStartIndex,UINT DestIndex,UINT VertexCount,IDirect3DVertexBuffer8* pDestBuffer,DWORD Flags) PURE;
299     STDMETHOD(CreateVertexShader)(THIS_ CONST DWORD* pDeclaration,CONST DWORD* pFunction,DWORD* pHandle,DWORD Usage) PURE;
300     STDMETHOD(SetVertexShader)(THIS_ DWORD Handle) PURE;
301     STDMETHOD(GetVertexShader)(THIS_ DWORD* pHandle) PURE;
302     STDMETHOD(DeleteVertexShader)(THIS_ DWORD Handle) PURE;
303     STDMETHOD(SetVertexShaderConstant)(THIS_ DWORD Register,CONST void* pConstantData,DWORD ConstantCount) PURE;
304     STDMETHOD(GetVertexShaderConstant)(THIS_ DWORD Register,void* pConstantData,DWORD ConstantCount) PURE;
305     STDMETHOD(GetVertexShaderDeclaration)(THIS_ DWORD Handle,void* pData,DWORD* pSizeOfData) PURE;
306     STDMETHOD(GetVertexShaderFunction)(THIS_ DWORD Handle,void* pData,DWORD* pSizeOfData) PURE;
307     STDMETHOD(SetStreamSource)(THIS_ UINT StreamNumber,IDirect3DVertexBuffer8* pStreamData,UINT Stride) PURE;
308     STDMETHOD(GetStreamSource)(THIS_ UINT StreamNumber,IDirect3DVertexBuffer8** ppStreamData,UINT* pStride) PURE;
309     STDMETHOD(SetIndices)(THIS_ IDirect3DIndexBuffer8* pIndexData,UINT BaseVertexIndex) PURE;
310     STDMETHOD(GetIndices)(THIS_ IDirect3DIndexBuffer8** ppIndexData,UINT* pBaseVertexIndex) PURE;
311     STDMETHOD(CreatePixelShader)(THIS_ CONST DWORD* pFunction,DWORD* pHandle) PURE;
312     STDMETHOD(SetPixelShader)(THIS_ DWORD Handle) PURE;
313     STDMETHOD(GetPixelShader)(THIS_ DWORD* pHandle) PURE;
314     STDMETHOD(DeletePixelShader)(THIS_ DWORD Handle) PURE;
315     STDMETHOD(SetPixelShaderConstant)(THIS_ DWORD Register,CONST void* pConstantData,DWORD ConstantCount) PURE;
316     STDMETHOD(GetPixelShaderConstant)(THIS_ DWORD Register,void* pConstantData,DWORD ConstantCount) PURE;
317     STDMETHOD(GetPixelShaderFunction)(THIS_ DWORD Handle,void* pData,DWORD* pSizeOfData) PURE;
318     STDMETHOD(DrawRectPatch)(THIS_ UINT Handle,CONST float* pNumSegs,CONST D3DRECTPATCH_INFO* pRectPatchInfo) PURE;
319     STDMETHOD(DrawTriPatch)(THIS_ UINT Handle,CONST float* pNumSegs,CONST D3DTRIPATCH_INFO* pTriPatchInfo) PURE;
320     STDMETHOD(DeletePatch)(THIS_ UINT Handle) PURE;
321 };
322 
323 typedef struct IDirect3DDevice8 *LPDIRECT3DDEVICE8, *PDIRECT3DDEVICE8;
324 
325 #if !defined(__cplusplus) || defined(CINTERFACE)
326 #define IDirect3DDevice8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
327 #define IDirect3DDevice8_AddRef(p) (p)->lpVtbl->AddRef(p)
328 #define IDirect3DDevice8_Release(p) (p)->lpVtbl->Release(p)
329 #define IDirect3DDevice8_TestCooperativeLevel(p) (p)->lpVtbl->TestCooperativeLevel(p)
330 #define IDirect3DDevice8_GetAvailableTextureMem(p) (p)->lpVtbl->GetAvailableTextureMem(p)
331 #define IDirect3DDevice8_ResourceManagerDiscardBytes(p,a) (p)->lpVtbl->ResourceManagerDiscardBytes(p,a)
332 #define IDirect3DDevice8_GetDirect3D(p,a) (p)->lpVtbl->GetDirect3D(p,a)
333 #define IDirect3DDevice8_GetDeviceCaps(p,a) (p)->lpVtbl->GetDeviceCaps(p,a)
334 #define IDirect3DDevice8_GetDisplayMode(p,a) (p)->lpVtbl->GetDisplayMode(p,a)
335 #define IDirect3DDevice8_GetCreationParameters(p,a) (p)->lpVtbl->GetCreationParameters(p,a)
336 #define IDirect3DDevice8_SetCursorProperties(p,a,b,c) (p)->lpVtbl->SetCursorProperties(p,a,b,c)
337 #define IDirect3DDevice8_SetCursorPosition(p,a,b,c) (p)->lpVtbl->SetCursorPosition(p,a,b,c)
338 #define IDirect3DDevice8_ShowCursor(p,a) (p)->lpVtbl->ShowCursor(p,a)
339 #define IDirect3DDevice8_CreateAdditionalSwapChain(p,a,b) (p)->lpVtbl->CreateAdditionalSwapChain(p,a,b)
340 #define IDirect3DDevice8_Reset(p,a) (p)->lpVtbl->Reset(p,a)
341 #define IDirect3DDevice8_Present(p,a,b,c,d) (p)->lpVtbl->Present(p,a,b,c,d)
342 #define IDirect3DDevice8_GetBackBuffer(p,a,b,c) (p)->lpVtbl->GetBackBuffer(p,a,b,c)
343 #define IDirect3DDevice8_GetRasterStatus(p,a) (p)->lpVtbl->GetRasterStatus(p,a)
344 #define IDirect3DDevice8_SetGammaRamp(p,a,b) (p)->lpVtbl->SetGammaRamp(p,a,b)
345 #define IDirect3DDevice8_GetGammaRamp(p,a) (p)->lpVtbl->GetGammaRamp(p,a)
346 #define IDirect3DDevice8_CreateTexture(p,a,b,c,d,e,f,g) (p)->lpVtbl->CreateTexture(p,a,b,c,d,e,f,g)
347 #define IDirect3DDevice8_CreateVolumeTexture(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->CreateVolumeTexture(p,a,b,c,d,e,f,g,h)
348 #define IDirect3DDevice8_CreateCubeTexture(p,a,b,c,d,e,f) (p)->lpVtbl->CreateCubeTexture(p,a,b,c,d,e,f)
349 #define IDirect3DDevice8_CreateVertexBuffer(p,a,b,c,d,e) (p)->lpVtbl->CreateVertexBuffer(p,a,b,c,d,e)
350 #define IDirect3DDevice8_CreateIndexBuffer(p,a,b,c,d,e) (p)->lpVtbl->CreateIndexBuffer(p,a,b,c,d,e)
351 #define IDirect3DDevice8_CreateRenderTarget(p,a,b,c,d,e,f) (p)->lpVtbl->CreateRenderTarget(p,a,b,c,d,e,f)
352 #define IDirect3DDevice8_CreateDepthStencilSurface(p,a,b,c,d,e) (p)->lpVtbl->CreateDepthStencilSurface(p,a,b,c,d,e)
353 #define IDirect3DDevice8_CreateImageSurface(p,a,b,c,d) (p)->lpVtbl->CreateImageSurface(p,a,b,c,d)
354 #define IDirect3DDevice8_CopyRects(p,a,b,c,d,e) (p)->lpVtbl->CopyRects(p,a,b,c,d,e)
355 #define IDirect3DDevice8_UpdateTexture(p,a,b) (p)->lpVtbl->UpdateTexture(p,a,b)
356 #define IDirect3DDevice8_GetFrontBuffer(p,a) (p)->lpVtbl->GetFrontBuffer(p,a)
357 #define IDirect3DDevice8_SetRenderTarget(p,a,b) (p)->lpVtbl->SetRenderTarget(p,a,b)
358 #define IDirect3DDevice8_GetRenderTarget(p,a) (p)->lpVtbl->GetRenderTarget(p,a)
359 #define IDirect3DDevice8_GetDepthStencilSurface(p,a) (p)->lpVtbl->GetDepthStencilSurface(p,a)
360 #define IDirect3DDevice8_BeginScene(p) (p)->lpVtbl->BeginScene(p)
361 #define IDirect3DDevice8_EndScene(p) (p)->lpVtbl->EndScene(p)
362 #define IDirect3DDevice8_Clear(p,a,b,c,d,e,f) (p)->lpVtbl->Clear(p,a,b,c,d,e,f)
363 #define IDirect3DDevice8_SetTransform(p,a,b) (p)->lpVtbl->SetTransform(p,a,b)
364 #define IDirect3DDevice8_GetTransform(p,a,b) (p)->lpVtbl->GetTransform(p,a,b)
365 #define IDirect3DDevice8_MultiplyTransform(p,a,b) (p)->lpVtbl->MultiplyTransform(p,a,b)
366 #define IDirect3DDevice8_SetViewport(p,a) (p)->lpVtbl->SetViewport(p,a)
367 #define IDirect3DDevice8_GetViewport(p,a) (p)->lpVtbl->GetViewport(p,a)
368 #define IDirect3DDevice8_SetMaterial(p,a) (p)->lpVtbl->SetMaterial(p,a)
369 #define IDirect3DDevice8_GetMaterial(p,a) (p)->lpVtbl->GetMaterial(p,a)
370 #define IDirect3DDevice8_SetLight(p,a,b) (p)->lpVtbl->SetLight(p,a,b)
371 #define IDirect3DDevice8_GetLight(p,a,b) (p)->lpVtbl->GetLight(p,a,b)
372 #define IDirect3DDevice8_LightEnable(p,a,b) (p)->lpVtbl->LightEnable(p,a,b)
373 #define IDirect3DDevice8_GetLightEnable(p,a,b) (p)->lpVtbl->GetLightEnable(p,a,b)
374 #define IDirect3DDevice8_SetClipPlane(p,a,b) (p)->lpVtbl->SetClipPlane(p,a,b)
375 #define IDirect3DDevice8_GetClipPlane(p,a,b) (p)->lpVtbl->GetClipPlane(p,a,b)
376 #define IDirect3DDevice8_SetRenderState(p,a,b) (p)->lpVtbl->SetRenderState(p,a,b)
377 #define IDirect3DDevice8_GetRenderState(p,a,b) (p)->lpVtbl->GetRenderState(p,a,b)
378 #define IDirect3DDevice8_BeginStateBlock(p) (p)->lpVtbl->BeginStateBlock(p)
379 #define IDirect3DDevice8_EndStateBlock(p,a) (p)->lpVtbl->EndStateBlock(p,a)
380 #define IDirect3DDevice8_ApplyStateBlock(p,a) (p)->lpVtbl->ApplyStateBlock(p,a)
381 #define IDirect3DDevice8_CaptureStateBlock(p,a) (p)->lpVtbl->CaptureStateBlock(p,a)
382 #define IDirect3DDevice8_DeleteStateBlock(p,a) (p)->lpVtbl->DeleteStateBlock(p,a)
383 #define IDirect3DDevice8_CreateStateBlock(p,a,b) (p)->lpVtbl->CreateStateBlock(p,a,b)
384 #define IDirect3DDevice8_SetClipStatus(p,a) (p)->lpVtbl->SetClipStatus(p,a)
385 #define IDirect3DDevice8_GetClipStatus(p,a) (p)->lpVtbl->GetClipStatus(p,a)
386 #define IDirect3DDevice8_GetTexture(p,a,b) (p)->lpVtbl->GetTexture(p,a,b)
387 #define IDirect3DDevice8_SetTexture(p,a,b) (p)->lpVtbl->SetTexture(p,a,b)
388 #define IDirect3DDevice8_GetTextureStageState(p,a,b,c) (p)->lpVtbl->GetTextureStageState(p,a,b,c)
389 #define IDirect3DDevice8_SetTextureStageState(p,a,b,c) (p)->lpVtbl->SetTextureStageState(p,a,b,c)
390 #define IDirect3DDevice8_ValidateDevice(p,a) (p)->lpVtbl->ValidateDevice(p,a)
391 #define IDirect3DDevice8_GetInfo(p,a,b,c) (p)->lpVtbl->GetInfo(p,a,b,c)
392 #define IDirect3DDevice8_SetPaletteEntries(p,a,b) (p)->lpVtbl->SetPaletteEntries(p,a,b)
393 #define IDirect3DDevice8_GetPaletteEntries(p,a,b) (p)->lpVtbl->GetPaletteEntries(p,a,b)
394 #define IDirect3DDevice8_SetCurrentTexturePalette(p,a) (p)->lpVtbl->SetCurrentTexturePalette(p,a)
395 #define IDirect3DDevice8_GetCurrentTexturePalette(p,a) (p)->lpVtbl->GetCurrentTexturePalette(p,a)
396 #define IDirect3DDevice8_DrawPrimitive(p,a,b,c) (p)->lpVtbl->DrawPrimitive(p,a,b,c)
397 #define IDirect3DDevice8_DrawIndexedPrimitive(p,a,b,c,d,e) (p)->lpVtbl->DrawIndexedPrimitive(p,a,b,c,d,e)
398 #define IDirect3DDevice8_DrawPrimitiveUP(p,a,b,c,d) (p)->lpVtbl->DrawPrimitiveUP(p,a,b,c,d)
399 #define IDirect3DDevice8_DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h)
400 #define IDirect3DDevice8_ProcessVertices(p,a,b,c,d,e) (p)->lpVtbl->ProcessVertices(p,a,b,c,d,e)
401 #define IDirect3DDevice8_CreateVertexShader(p,a,b,c,d) (p)->lpVtbl->CreateVertexShader(p,a,b,c,d)
402 #define IDirect3DDevice8_SetVertexShader(p,a) (p)->lpVtbl->SetVertexShader(p,a)
403 #define IDirect3DDevice8_GetVertexShader(p,a) (p)->lpVtbl->GetVertexShader(p,a)
404 #define IDirect3DDevice8_DeleteVertexShader(p,a) (p)->lpVtbl->DeleteVertexShader(p,a)
405 #define IDirect3DDevice8_SetVertexShaderConstant(p,a,b,c) (p)->lpVtbl->SetVertexShaderConstant(p,a,b,c)
406 #define IDirect3DDevice8_GetVertexShaderConstant(p,a,b,c) (p)->lpVtbl->GetVertexShaderConstant(p,a,b,c)
407 #define IDirect3DDevice8_GetVertexShaderDeclaration(p,a,b,c) (p)->lpVtbl->GetVertexShaderDeclaration(p,a,b,c)
408 #define IDirect3DDevice8_GetVertexShaderFunction(p,a,b,c) (p)->lpVtbl->GetVertexShaderFunction(p,a,b,c)
409 #define IDirect3DDevice8_SetStreamSource(p,a,b,c) (p)->lpVtbl->SetStreamSource(p,a,b,c)
410 #define IDirect3DDevice8_GetStreamSource(p,a,b,c) (p)->lpVtbl->GetStreamSource(p,a,b,c)
411 #define IDirect3DDevice8_SetIndices(p,a,b) (p)->lpVtbl->SetIndices(p,a,b)
412 #define IDirect3DDevice8_GetIndices(p,a,b) (p)->lpVtbl->GetIndices(p,a,b)
413 #define IDirect3DDevice8_CreatePixelShader(p,a,b) (p)->lpVtbl->CreatePixelShader(p,a,b)
414 #define IDirect3DDevice8_SetPixelShader(p,a) (p)->lpVtbl->SetPixelShader(p,a)
415 #define IDirect3DDevice8_GetPixelShader(p,a) (p)->lpVtbl->GetPixelShader(p,a)
416 #define IDirect3DDevice8_DeletePixelShader(p,a) (p)->lpVtbl->DeletePixelShader(p,a)
417 #define IDirect3DDevice8_SetPixelShaderConstant(p,a,b,c) (p)->lpVtbl->SetPixelShaderConstant(p,a,b,c)
418 #define IDirect3DDevice8_GetPixelShaderConstant(p,a,b,c) (p)->lpVtbl->GetPixelShaderConstant(p,a,b,c)
419 #define IDirect3DDevice8_GetPixelShaderFunction(p,a,b,c) (p)->lpVtbl->GetPixelShaderFunction(p,a,b,c)
420 #define IDirect3DDevice8_DrawRectPatch(p,a,b,c) (p)->lpVtbl->DrawRectPatch(p,a,b,c)
421 #define IDirect3DDevice8_DrawTriPatch(p,a,b,c) (p)->lpVtbl->DrawTriPatch(p,a,b,c)
422 #define IDirect3DDevice8_DeletePatch(p,a) (p)->lpVtbl->DeletePatch(p,a)
423 #else
424 #define IDirect3DDevice8_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
425 #define IDirect3DDevice8_AddRef(p) (p)->AddRef()
426 #define IDirect3DDevice8_Release(p) (p)->Release()
427 #define IDirect3DDevice8_TestCooperativeLevel(p) (p)->TestCooperativeLevel()
428 #define IDirect3DDevice8_GetAvailableTextureMem(p) (p)->GetAvailableTextureMem()
429 #define IDirect3DDevice8_ResourceManagerDiscardBytes(p,a) (p)->ResourceManagerDiscardBytes(a)
430 #define IDirect3DDevice8_GetDirect3D(p,a) (p)->GetDirect3D(a)
431 #define IDirect3DDevice8_GetDeviceCaps(p,a) (p)->GetDeviceCaps(a)
432 #define IDirect3DDevice8_GetDisplayMode(p,a) (p)->GetDisplayMode(a)
433 #define IDirect3DDevice8_GetCreationParameters(p,a) (p)->GetCreationParameters(a)
434 #define IDirect3DDevice8_SetCursorProperties(p,a,b,c) (p)->SetCursorProperties(a,b,c)
435 #define IDirect3DDevice8_SetCursorPosition(p,a,b,c) (p)->SetCursorPosition(a,b,c)
436 #define IDirect3DDevice8_ShowCursor(p,a) (p)->ShowCursor(a)
437 #define IDirect3DDevice8_CreateAdditionalSwapChain(p,a,b) (p)->CreateAdditionalSwapChain(a,b)
438 #define IDirect3DDevice8_Reset(p,a) (p)->Reset(a)
439 #define IDirect3DDevice8_Present(p,a,b,c,d) (p)->Present(a,b,c,d)
440 #define IDirect3DDevice8_GetBackBuffer(p,a,b,c) (p)->GetBackBuffer(a,b,c)
441 #define IDirect3DDevice8_GetRasterStatus(p,a) (p)->GetRasterStatus(a)
442 #define IDirect3DDevice8_SetGammaRamp(p,a,b) (p)->SetGammaRamp(a,b)
443 #define IDirect3DDevice8_GetGammaRamp(p,a) (p)->GetGammaRamp(a)
444 #define IDirect3DDevice8_CreateTexture(p,a,b,c,d,e,f,g) (p)->CreateTexture(a,b,c,d,e,f,g)
445 #define IDirect3DDevice8_CreateVolumeTexture(p,a,b,c,d,e,f,g,h) (p)->CreateVolumeTexture(a,b,c,d,e,f,g,h)
446 #define IDirect3DDevice8_CreateCubeTexture(p,a,b,c,d,e,f) (p)->CreateCubeTexture(a,b,c,d,e,f)
447 #define IDirect3DDevice8_CreateVertexBuffer(p,a,b,c,d,e) (p)->CreateVertexBuffer(a,b,c,d,e)
448 #define IDirect3DDevice8_CreateIndexBuffer(p,a,b,c,d,e) (p)->CreateIndexBuffer(a,b,c,d,e)
449 #define IDirect3DDevice8_CreateRenderTarget(p,a,b,c,d,e,f) (p)->CreateRenderTarget(a,b,c,d,e,f)
450 #define IDirect3DDevice8_CreateDepthStencilSurface(p,a,b,c,d,e) (p)->CreateDepthStencilSurface(a,b,c,d,e)
451 #define IDirect3DDevice8_CreateImageSurface(p,a,b,c,d) (p)->CreateImageSurface(a,b,c,d)
452 #define IDirect3DDevice8_CopyRects(p,a,b,c,d,e) (p)->CopyRects(a,b,c,d,e)
453 #define IDirect3DDevice8_UpdateTexture(p,a,b) (p)->UpdateTexture(a,b)
454 #define IDirect3DDevice8_GetFrontBuffer(p,a) (p)->GetFrontBuffer(a)
455 #define IDirect3DDevice8_SetRenderTarget(p,a,b) (p)->SetRenderTarget(a,b)
456 #define IDirect3DDevice8_GetRenderTarget(p,a) (p)->GetRenderTarget(a)
457 #define IDirect3DDevice8_GetDepthStencilSurface(p,a) (p)->GetDepthStencilSurface(a)
458 #define IDirect3DDevice8_BeginScene(p) (p)->BeginScene()
459 #define IDirect3DDevice8_EndScene(p) (p)->EndScene()
460 #define IDirect3DDevice8_Clear(p,a,b,c,d,e,f) (p)->Clear(a,b,c,d,e,f)
461 #define IDirect3DDevice8_SetTransform(p,a,b) (p)->SetTransform(a,b)
462 #define IDirect3DDevice8_GetTransform(p,a,b) (p)->GetTransform(a,b)
463 #define IDirect3DDevice8_MultiplyTransform(p,a,b) (p)->MultiplyTransform(a,b)
464 #define IDirect3DDevice8_SetViewport(p,a) (p)->SetViewport(a)
465 #define IDirect3DDevice8_GetViewport(p,a) (p)->GetViewport(a)
466 #define IDirect3DDevice8_SetMaterial(p,a) (p)->SetMaterial(a)
467 #define IDirect3DDevice8_GetMaterial(p,a) (p)->GetMaterial(a)
468 #define IDirect3DDevice8_SetLight(p,a,b) (p)->SetLight(a,b)
469 #define IDirect3DDevice8_GetLight(p,a,b) (p)->GetLight(a,b)
470 #define IDirect3DDevice8_LightEnable(p,a,b) (p)->LightEnable(a,b)
471 #define IDirect3DDevice8_GetLightEnable(p,a,b) (p)->GetLightEnable(a,b)
472 #define IDirect3DDevice8_SetClipPlane(p,a,b) (p)->SetClipPlane(a,b)
473 #define IDirect3DDevice8_GetClipPlane(p,a,b) (p)->GetClipPlane(a,b)
474 #define IDirect3DDevice8_SetRenderState(p,a,b) (p)->SetRenderState(a,b)
475 #define IDirect3DDevice8_GetRenderState(p,a,b) (p)->GetRenderState(a,b)
476 #define IDirect3DDevice8_BeginStateBlock(p) (p)->BeginStateBlock()
477 #define IDirect3DDevice8_EndStateBlock(p,a) (p)->EndStateBlock(a)
478 #define IDirect3DDevice8_ApplyStateBlock(p,a) (p)->ApplyStateBlock(a)
479 #define IDirect3DDevice8_CaptureStateBlock(p,a) (p)->CaptureStateBlock(a)
480 #define IDirect3DDevice8_DeleteStateBlock(p,a) (p)->DeleteStateBlock(a)
481 #define IDirect3DDevice8_CreateStateBlock(p,a,b) (p)->CreateStateBlock(a,b)
482 #define IDirect3DDevice8_SetClipStatus(p,a) (p)->SetClipStatus(a)
483 #define IDirect3DDevice8_GetClipStatus(p,a) (p)->GetClipStatus(a)
484 #define IDirect3DDevice8_GetTexture(p,a,b) (p)->GetTexture(a,b)
485 #define IDirect3DDevice8_SetTexture(p,a,b) (p)->SetTexture(a,b)
486 #define IDirect3DDevice8_GetTextureStageState(p,a,b,c) (p)->GetTextureStageState(a,b,c)
487 #define IDirect3DDevice8_SetTextureStageState(p,a,b,c) (p)->SetTextureStageState(a,b,c)
488 #define IDirect3DDevice8_ValidateDevice(p,a) (p)->ValidateDevice(a)
489 #define IDirect3DDevice8_GetInfo(p,a,b,c) (p)->GetInfo(a,b,c)
490 #define IDirect3DDevice8_SetPaletteEntries(p,a,b) (p)->SetPaletteEntries(a,b)
491 #define IDirect3DDevice8_GetPaletteEntries(p,a,b) (p)->GetPaletteEntries(a,b)
492 #define IDirect3DDevice8_SetCurrentTexturePalette(p,a) (p)->SetCurrentTexturePalette(a)
493 #define IDirect3DDevice8_GetCurrentTexturePalette(p,a) (p)->GetCurrentTexturePalette(a)
494 #define IDirect3DDevice8_DrawPrimitive(p,a,b,c) (p)->DrawPrimitive(a,b,c)
495 #define IDirect3DDevice8_DrawIndexedPrimitive(p,a,b,c,d,e) (p)->DrawIndexedPrimitive(a,b,c,d,e)
496 #define IDirect3DDevice8_DrawPrimitiveUP(p,a,b,c,d) (p)->DrawPrimitiveUP(a,b,c,d)
497 #define IDirect3DDevice8_DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h) (p)->DrawIndexedPrimitiveUP(a,b,c,d,e,f,g,h)
498 #define IDirect3DDevice8_ProcessVertices(p,a,b,c,d,e) (p)->ProcessVertices(a,b,c,d,e)
499 #define IDirect3DDevice8_CreateVertexShader(p,a,b,c,d) (p)->CreateVertexShader(a,b,c,d)
500 #define IDirect3DDevice8_SetVertexShader(p,a) (p)->SetVertexShader(a)
501 #define IDirect3DDevice8_GetVertexShader(p,a) (p)->GetVertexShader(a)
502 #define IDirect3DDevice8_DeleteVertexShader(p,a) (p)->DeleteVertexShader(a)
503 #define IDirect3DDevice8_SetVertexShaderConstant(p,a,b,c) (p)->SetVertexShaderConstant(a,b,c)
504 #define IDirect3DDevice8_GetVertexShaderConstant(p,a,b,c) (p)->GetVertexShaderConstant(a,b,c)
505 #define IDirect3DDevice8_GetVertexShaderDeclaration(p,a,b,c) (p)->GetVertexShaderDeclaration(a,b,c)
506 #define IDirect3DDevice8_GetVertexShaderFunction(p,a,b,c) (p)->GetVertexShaderFunction(a,b,c)
507 #define IDirect3DDevice8_SetStreamSource(p,a,b,c) (p)->SetStreamSource(a,b,c)
508 #define IDirect3DDevice8_GetStreamSource(p,a,b,c) (p)->GetStreamSource(a,b,c)
509 #define IDirect3DDevice8_SetIndices(p,a,b) (p)->SetIndices(a,b)
510 #define IDirect3DDevice8_GetIndices(p,a,b) (p)->GetIndices(a,b)
511 #define IDirect3DDevice8_CreatePixelShader(p,a,b) (p)->CreatePixelShader(a,b)
512 #define IDirect3DDevice8_SetPixelShader(p,a) (p)->SetPixelShader(a)
513 #define IDirect3DDevice8_GetPixelShader(p,a) (p)->GetPixelShader(a)
514 #define IDirect3DDevice8_DeletePixelShader(p,a) (p)->DeletePixelShader(a)
515 #define IDirect3DDevice8_SetPixelShaderConstant(p,a,b,c) (p)->SetPixelShaderConstant(a,b,c)
516 #define IDirect3DDevice8_GetPixelShaderConstant(p,a,b,c) (p)->GetPixelShaderConstant(a,b,c)
517 #define IDirect3DDevice8_GetPixelShaderFunction(p,a,b,c) (p)->GetPixelShaderFunction(a,b,c)
518 #define IDirect3DDevice8_DrawRectPatch(p,a,b,c) (p)->DrawRectPatch(a,b,c)
519 #define IDirect3DDevice8_DrawTriPatch(p,a,b,c) (p)->DrawTriPatch(a,b,c)
520 #define IDirect3DDevice8_DeletePatch(p,a) (p)->DeletePatch(a)
521 #endif
522 
523 #undef INTERFACE
524 #define INTERFACE IDirect3DSwapChain8
525 
DECLARE_INTERFACE_(IDirect3DSwapChain8,IUnknown)526 DECLARE_INTERFACE_(IDirect3DSwapChain8, IUnknown)
527 {
528     /*** IUnknown methods ***/
529     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
530     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
531     STDMETHOD_(ULONG,Release)(THIS) PURE;
532 
533     /*** IDirect3DSwapChain8 methods ***/
534     STDMETHOD(Present)(THIS_ CONST RECT* pSourceRect,CONST RECT* pDestRect,HWND hDestWindowOverride,CONST RGNDATA* pDirtyRegion) PURE;
535     STDMETHOD(GetBackBuffer)(THIS_ UINT BackBuffer,D3DBACKBUFFER_TYPE Type,IDirect3DSurface8** ppBackBuffer) PURE;
536 };
537 
538 typedef struct IDirect3DSwapChain8 *LPDIRECT3DSWAPCHAIN8, *PDIRECT3DSWAPCHAIN8;
539 
540 #if !defined(__cplusplus) || defined(CINTERFACE)
541 #define IDirect3DSwapChain8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
542 #define IDirect3DSwapChain8_AddRef(p) (p)->lpVtbl->AddRef(p)
543 #define IDirect3DSwapChain8_Release(p) (p)->lpVtbl->Release(p)
544 #define IDirect3DSwapChain8_Present(p,a,b,c,d) (p)->lpVtbl->Present(p,a,b,c,d)
545 #define IDirect3DSwapChain8_GetBackBuffer(p,a,b,c) (p)->lpVtbl->GetBackBuffer(p,a,b,c)
546 #else
547 #define IDirect3DSwapChain8_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
548 #define IDirect3DSwapChain8_AddRef(p) (p)->AddRef()
549 #define IDirect3DSwapChain8_Release(p) (p)->Release()
550 #define IDirect3DSwapChain8_Present(p,a,b,c,d) (p)->Present(a,b,c,d)
551 #define IDirect3DSwapChain8_GetBackBuffer(p,a,b,c) (p)->GetBackBuffer(a,b,c)
552 #endif
553 
554 #undef INTERFACE
555 #define INTERFACE IDirect3DResource8
556 
DECLARE_INTERFACE_(IDirect3DResource8,IUnknown)557 DECLARE_INTERFACE_(IDirect3DResource8, IUnknown)
558 {
559     /*** IUnknown methods ***/
560     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
561     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
562     STDMETHOD_(ULONG,Release)(THIS) PURE;
563 
564     /*** IDirect3DResource8 methods ***/
565     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE;
566     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
567     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
568     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
569     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
570     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
571     STDMETHOD_(void, PreLoad)(THIS) PURE;
572     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
573 };
574 
575 typedef struct IDirect3DResource8 *LPDIRECT3DRESOURCE8, *PDIRECT3DRESOURCE8;
576 
577 #if !defined(__cplusplus) || defined(CINTERFACE)
578 #define IDirect3DResource8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
579 #define IDirect3DResource8_AddRef(p) (p)->lpVtbl->AddRef(p)
580 #define IDirect3DResource8_Release(p) (p)->lpVtbl->Release(p)
581 #define IDirect3DResource8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
582 #define IDirect3DResource8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
583 #define IDirect3DResource8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
584 #define IDirect3DResource8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
585 #define IDirect3DResource8_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
586 #define IDirect3DResource8_GetPriority(p) (p)->lpVtbl->GetPriority(p)
587 #define IDirect3DResource8_PreLoad(p) (p)->lpVtbl->PreLoad(p)
588 #define IDirect3DResource8_GetType(p) (p)->lpVtbl->GetType(p)
589 #else
590 #define IDirect3DResource8_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
591 #define IDirect3DResource8_AddRef(p) (p)->AddRef()
592 #define IDirect3DResource8_Release(p) (p)->Release()
593 #define IDirect3DResource8_GetDevice(p,a) (p)->GetDevice(a)
594 #define IDirect3DResource8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
595 #define IDirect3DResource8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
596 #define IDirect3DResource8_FreePrivateData(p,a) (p)->FreePrivateData(a)
597 #define IDirect3DResource8_SetPriority(p,a) (p)->SetPriority(a)
598 #define IDirect3DResource8_GetPriority(p) (p)->GetPriority()
599 #define IDirect3DResource8_PreLoad(p) (p)->PreLoad()
600 #define IDirect3DResource8_GetType(p) (p)->GetType()
601 #endif
602 
603 #undef INTERFACE
604 #define INTERFACE IDirect3DBaseTexture8
605 
DECLARE_INTERFACE_(IDirect3DBaseTexture8,IDirect3DResource8)606 DECLARE_INTERFACE_(IDirect3DBaseTexture8, IDirect3DResource8)
607 {
608     /*** IUnknown methods ***/
609     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
610     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
611     STDMETHOD_(ULONG,Release)(THIS) PURE;
612 
613     /*** IDirect3DResource8 methods ***/
614     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE;
615     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
616     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
617     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
618     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
619     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
620     STDMETHOD_(void, PreLoad)(THIS) PURE;
621     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
622     STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE;
623     STDMETHOD_(DWORD, GetLOD)(THIS) PURE;
624     STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE;
625 };
626 
627 typedef struct IDirect3DBaseTexture8 *LPDIRECT3DBASETEXTURE8, *PDIRECT3DBASETEXTURE8;
628 
629 #if !defined(__cplusplus) || defined(CINTERFACE)
630 #define IDirect3DBaseTexture8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
631 #define IDirect3DBaseTexture8_AddRef(p) (p)->lpVtbl->AddRef(p)
632 #define IDirect3DBaseTexture8_Release(p) (p)->lpVtbl->Release(p)
633 #define IDirect3DBaseTexture8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
634 #define IDirect3DBaseTexture8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
635 #define IDirect3DBaseTexture8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
636 #define IDirect3DBaseTexture8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
637 #define IDirect3DBaseTexture8_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
638 #define IDirect3DBaseTexture8_GetPriority(p) (p)->lpVtbl->GetPriority(p)
639 #define IDirect3DBaseTexture8_PreLoad(p) (p)->lpVtbl->PreLoad(p)
640 #define IDirect3DBaseTexture8_GetType(p) (p)->lpVtbl->GetType(p)
641 #define IDirect3DBaseTexture8_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a)
642 #define IDirect3DBaseTexture8_GetLOD(p) (p)->lpVtbl->GetLOD(p)
643 #define IDirect3DBaseTexture8_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p)
644 #else
645 #define IDirect3DBaseTexture8_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
646 #define IDirect3DBaseTexture8_AddRef(p) (p)->AddRef()
647 #define IDirect3DBaseTexture8_Release(p) (p)->Release()
648 #define IDirect3DBaseTexture8_GetDevice(p,a) (p)->GetDevice(a)
649 #define IDirect3DBaseTexture8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
650 #define IDirect3DBaseTexture8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
651 #define IDirect3DBaseTexture8_FreePrivateData(p,a) (p)->FreePrivateData(a)
652 #define IDirect3DBaseTexture8_SetPriority(p,a) (p)->SetPriority(a)
653 #define IDirect3DBaseTexture8_GetPriority(p) (p)->GetPriority()
654 #define IDirect3DBaseTexture8_PreLoad(p) (p)->PreLoad()
655 #define IDirect3DBaseTexture8_GetType(p) (p)->GetType()
656 #define IDirect3DBaseTexture8_SetLOD(p,a) (p)->SetLOD(a)
657 #define IDirect3DBaseTexture8_GetLOD(p) (p)->GetLOD()
658 #define IDirect3DBaseTexture8_GetLevelCount(p) (p)->GetLevelCount()
659 #endif
660 
661 #undef INTERFACE
662 #define INTERFACE IDirect3DTexture8
663 
DECLARE_INTERFACE_(IDirect3DTexture8,IDirect3DBaseTexture8)664 DECLARE_INTERFACE_(IDirect3DTexture8, IDirect3DBaseTexture8)
665 {
666     /*** IUnknown methods ***/
667     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
668     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
669     STDMETHOD_(ULONG,Release)(THIS) PURE;
670 
671     /*** IDirect3DBaseTexture8 methods ***/
672     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE;
673     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
674     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
675     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
676     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
677     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
678     STDMETHOD_(void, PreLoad)(THIS) PURE;
679     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
680     STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE;
681     STDMETHOD_(DWORD, GetLOD)(THIS) PURE;
682     STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE;
683     STDMETHOD(GetLevelDesc)(THIS_ UINT Level,D3DSURFACE_DESC *pDesc) PURE;
684     STDMETHOD(GetSurfaceLevel)(THIS_ UINT Level,IDirect3DSurface8** ppSurfaceLevel) PURE;
685     STDMETHOD(LockRect)(THIS_ UINT Level,D3DLOCKED_RECT* pLockedRect,CONST RECT* pRect,DWORD Flags) PURE;
686     STDMETHOD(UnlockRect)(THIS_ UINT Level) PURE;
687     STDMETHOD(AddDirtyRect)(THIS_ CONST RECT* pDirtyRect) PURE;
688 };
689 
690 typedef struct IDirect3DTexture8 *LPDIRECT3DTEXTURE8, *PDIRECT3DTEXTURE8;
691 
692 #if !defined(__cplusplus) || defined(CINTERFACE)
693 #define IDirect3DTexture8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
694 #define IDirect3DTexture8_AddRef(p) (p)->lpVtbl->AddRef(p)
695 #define IDirect3DTexture8_Release(p) (p)->lpVtbl->Release(p)
696 #define IDirect3DTexture8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
697 #define IDirect3DTexture8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
698 #define IDirect3DTexture8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
699 #define IDirect3DTexture8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
700 #define IDirect3DTexture8_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
701 #define IDirect3DTexture8_GetPriority(p) (p)->lpVtbl->GetPriority(p)
702 #define IDirect3DTexture8_PreLoad(p) (p)->lpVtbl->PreLoad(p)
703 #define IDirect3DTexture8_GetType(p) (p)->lpVtbl->GetType(p)
704 #define IDirect3DTexture8_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a)
705 #define IDirect3DTexture8_GetLOD(p) (p)->lpVtbl->GetLOD(p)
706 #define IDirect3DTexture8_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p)
707 #define IDirect3DTexture8_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b)
708 #define IDirect3DTexture8_GetSurfaceLevel(p,a,b) (p)->lpVtbl->GetSurfaceLevel(p,a,b)
709 #define IDirect3DTexture8_LockRect(p,a,b,c,d) (p)->lpVtbl->LockRect(p,a,b,c,d)
710 #define IDirect3DTexture8_UnlockRect(p,a) (p)->lpVtbl->UnlockRect(p,a)
711 #define IDirect3DTexture8_AddDirtyRect(p,a) (p)->lpVtbl->AddDirtyRect(p,a)
712 #else
713 #define IDirect3DTexture8_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
714 #define IDirect3DTexture8_AddRef(p) (p)->AddRef()
715 #define IDirect3DTexture8_Release(p) (p)->Release()
716 #define IDirect3DTexture8_GetDevice(p,a) (p)->GetDevice(a)
717 #define IDirect3DTexture8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
718 #define IDirect3DTexture8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
719 #define IDirect3DTexture8_FreePrivateData(p,a) (p)->FreePrivateData(a)
720 #define IDirect3DTexture8_SetPriority(p,a) (p)->SetPriority(a)
721 #define IDirect3DTexture8_GetPriority(p) (p)->GetPriority()
722 #define IDirect3DTexture8_PreLoad(p) (p)->PreLoad()
723 #define IDirect3DTexture8_GetType(p) (p)->GetType()
724 #define IDirect3DTexture8_SetLOD(p,a) (p)->SetLOD(a)
725 #define IDirect3DTexture8_GetLOD(p) (p)->GetLOD()
726 #define IDirect3DTexture8_GetLevelCount(p) (p)->GetLevelCount()
727 #define IDirect3DTexture8_GetLevelDesc(p,a,b) (p)->GetLevelDesc(a,b)
728 #define IDirect3DTexture8_GetSurfaceLevel(p,a,b) (p)->GetSurfaceLevel(a,b)
729 #define IDirect3DTexture8_LockRect(p,a,b,c,d) (p)->LockRect(a,b,c,d)
730 #define IDirect3DTexture8_UnlockRect(p,a) (p)->UnlockRect(a)
731 #define IDirect3DTexture8_AddDirtyRect(p,a) (p)->AddDirtyRect(a)
732 #endif
733 
734 #undef INTERFACE
735 #define INTERFACE IDirect3DVolumeTexture8
736 
DECLARE_INTERFACE_(IDirect3DVolumeTexture8,IDirect3DBaseTexture8)737 DECLARE_INTERFACE_(IDirect3DVolumeTexture8, IDirect3DBaseTexture8)
738 {
739     /*** IUnknown methods ***/
740     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
741     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
742     STDMETHOD_(ULONG,Release)(THIS) PURE;
743 
744     /*** IDirect3DBaseTexture8 methods ***/
745     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE;
746     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
747     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
748     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
749     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
750     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
751     STDMETHOD_(void, PreLoad)(THIS) PURE;
752     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
753     STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE;
754     STDMETHOD_(DWORD, GetLOD)(THIS) PURE;
755     STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE;
756     STDMETHOD(GetLevelDesc)(THIS_ UINT Level,D3DVOLUME_DESC *pDesc) PURE;
757     STDMETHOD(GetVolumeLevel)(THIS_ UINT Level,IDirect3DVolume8** ppVolumeLevel) PURE;
758     STDMETHOD(LockBox)(THIS_ UINT Level,D3DLOCKED_BOX* pLockedVolume,CONST D3DBOX* pBox,DWORD Flags) PURE;
759     STDMETHOD(UnlockBox)(THIS_ UINT Level) PURE;
760     STDMETHOD(AddDirtyBox)(THIS_ CONST D3DBOX* pDirtyBox) PURE;
761 };
762 
763 typedef struct IDirect3DVolumeTexture8 *LPDIRECT3DVOLUMETEXTURE8, *PDIRECT3DVOLUMETEXTURE8;
764 
765 #if !defined(__cplusplus) || defined(CINTERFACE)
766 #define IDirect3DVolumeTexture8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
767 #define IDirect3DVolumeTexture8_AddRef(p) (p)->lpVtbl->AddRef(p)
768 #define IDirect3DVolumeTexture8_Release(p) (p)->lpVtbl->Release(p)
769 #define IDirect3DVolumeTexture8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
770 #define IDirect3DVolumeTexture8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
771 #define IDirect3DVolumeTexture8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
772 #define IDirect3DVolumeTexture8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
773 #define IDirect3DVolumeTexture8_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
774 #define IDirect3DVolumeTexture8_GetPriority(p) (p)->lpVtbl->GetPriority(p)
775 #define IDirect3DVolumeTexture8_PreLoad(p) (p)->lpVtbl->PreLoad(p)
776 #define IDirect3DVolumeTexture8_GetType(p) (p)->lpVtbl->GetType(p)
777 #define IDirect3DVolumeTexture8_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a)
778 #define IDirect3DVolumeTexture8_GetLOD(p) (p)->lpVtbl->GetLOD(p)
779 #define IDirect3DVolumeTexture8_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p)
780 #define IDirect3DVolumeTexture8_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b)
781 #define IDirect3DVolumeTexture8_GetVolumeLevel(p,a,b) (p)->lpVtbl->GetVolumeLevel(p,a,b)
782 #define IDirect3DVolumeTexture8_LockBox(p,a,b,c,d) (p)->lpVtbl->LockBox(p,a,b,c,d)
783 #define IDirect3DVolumeTexture8_UnlockBox(p,a) (p)->lpVtbl->UnlockBox(p,a)
784 #define IDirect3DVolumeTexture8_AddDirtyBox(p,a) (p)->lpVtbl->AddDirtyBox(p,a)
785 #else
786 #define IDirect3DVolumeTexture8_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
787 #define IDirect3DVolumeTexture8_AddRef(p) (p)->AddRef()
788 #define IDirect3DVolumeTexture8_Release(p) (p)->Release()
789 #define IDirect3DVolumeTexture8_GetDevice(p,a) (p)->GetDevice(a)
790 #define IDirect3DVolumeTexture8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
791 #define IDirect3DVolumeTexture8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
792 #define IDirect3DVolumeTexture8_FreePrivateData(p,a) (p)->FreePrivateData(a)
793 #define IDirect3DVolumeTexture8_SetPriority(p,a) (p)->SetPriority(a)
794 #define IDirect3DVolumeTexture8_GetPriority(p) (p)->GetPriority()
795 #define IDirect3DVolumeTexture8_PreLoad(p) (p)->PreLoad()
796 #define IDirect3DVolumeTexture8_GetType(p) (p)->GetType()
797 #define IDirect3DVolumeTexture8_SetLOD(p,a) (p)->SetLOD(a)
798 #define IDirect3DVolumeTexture8_GetLOD(p) (p)->GetLOD()
799 #define IDirect3DVolumeTexture8_GetLevelCount(p) (p)->GetLevelCount()
800 #define IDirect3DVolumeTexture8_GetLevelDesc(p,a,b) (p)->GetLevelDesc(a,b)
801 #define IDirect3DVolumeTexture8_GetVolumeLevel(p,a,b) (p)->GetVolumeLevel(a,b)
802 #define IDirect3DVolumeTexture8_LockBox(p,a,b,c,d) (p)->LockBox(a,b,c,d)
803 #define IDirect3DVolumeTexture8_UnlockBox(p,a) (p)->UnlockBox(a)
804 #define IDirect3DVolumeTexture8_AddDirtyBox(p,a) (p)->AddDirtyBox(a)
805 #endif
806 
807 #undef INTERFACE
808 #define INTERFACE IDirect3DCubeTexture8
809 
DECLARE_INTERFACE_(IDirect3DCubeTexture8,IDirect3DBaseTexture8)810 DECLARE_INTERFACE_(IDirect3DCubeTexture8, IDirect3DBaseTexture8)
811 {
812     /*** IUnknown methods ***/
813     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
814     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
815     STDMETHOD_(ULONG,Release)(THIS) PURE;
816 
817     /*** IDirect3DBaseTexture8 methods ***/
818     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE;
819     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
820     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
821     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
822     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
823     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
824     STDMETHOD_(void, PreLoad)(THIS) PURE;
825     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
826     STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE;
827     STDMETHOD_(DWORD, GetLOD)(THIS) PURE;
828     STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE;
829     STDMETHOD(GetLevelDesc)(THIS_ UINT Level,D3DSURFACE_DESC *pDesc) PURE;
830     STDMETHOD(GetCubeMapSurface)(THIS_ D3DCUBEMAP_FACES FaceType,UINT Level,IDirect3DSurface8** ppCubeMapSurface) PURE;
831     STDMETHOD(LockRect)(THIS_ D3DCUBEMAP_FACES FaceType,UINT Level,D3DLOCKED_RECT* pLockedRect,CONST RECT* pRect,DWORD Flags) PURE;
832     STDMETHOD(UnlockRect)(THIS_ D3DCUBEMAP_FACES FaceType,UINT Level) PURE;
833     STDMETHOD(AddDirtyRect)(THIS_ D3DCUBEMAP_FACES FaceType,CONST RECT* pDirtyRect) PURE;
834 };
835 
836 typedef struct IDirect3DCubeTexture8 *LPDIRECT3DCUBETEXTURE8, *PDIRECT3DCUBETEXTURE8;
837 
838 #if !defined(__cplusplus) || defined(CINTERFACE)
839 #define IDirect3DCubeTexture8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
840 #define IDirect3DCubeTexture8_AddRef(p) (p)->lpVtbl->AddRef(p)
841 #define IDirect3DCubeTexture8_Release(p) (p)->lpVtbl->Release(p)
842 #define IDirect3DCubeTexture8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
843 #define IDirect3DCubeTexture8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
844 #define IDirect3DCubeTexture8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
845 #define IDirect3DCubeTexture8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
846 #define IDirect3DCubeTexture8_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
847 #define IDirect3DCubeTexture8_GetPriority(p) (p)->lpVtbl->GetPriority(p)
848 #define IDirect3DCubeTexture8_PreLoad(p) (p)->lpVtbl->PreLoad(p)
849 #define IDirect3DCubeTexture8_GetType(p) (p)->lpVtbl->GetType(p)
850 #define IDirect3DCubeTexture8_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a)
851 #define IDirect3DCubeTexture8_GetLOD(p) (p)->lpVtbl->GetLOD(p)
852 #define IDirect3DCubeTexture8_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p)
853 #define IDirect3DCubeTexture8_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b)
854 #define IDirect3DCubeTexture8_GetCubeMapSurface(p,a,b,c) (p)->lpVtbl->GetCubeMapSurface(p,a,b,c)
855 #define IDirect3DCubeTexture8_LockRect(p,a,b,c,d,e) (p)->lpVtbl->LockRect(p,a,b,c,d,e)
856 #define IDirect3DCubeTexture8_UnlockRect(p,a,b) (p)->lpVtbl->UnlockRect(p,a,b)
857 #define IDirect3DCubeTexture8_AddDirtyRect(p,a,b) (p)->lpVtbl->AddDirtyRect(p,a,b)
858 #else
859 #define IDirect3DCubeTexture8_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
860 #define IDirect3DCubeTexture8_AddRef(p) (p)->AddRef()
861 #define IDirect3DCubeTexture8_Release(p) (p)->Release()
862 #define IDirect3DCubeTexture8_GetDevice(p,a) (p)->GetDevice(a)
863 #define IDirect3DCubeTexture8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
864 #define IDirect3DCubeTexture8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
865 #define IDirect3DCubeTexture8_FreePrivateData(p,a) (p)->FreePrivateData(a)
866 #define IDirect3DCubeTexture8_SetPriority(p,a) (p)->SetPriority(a)
867 #define IDirect3DCubeTexture8_GetPriority(p) (p)->GetPriority()
868 #define IDirect3DCubeTexture8_PreLoad(p) (p)->PreLoad()
869 #define IDirect3DCubeTexture8_GetType(p) (p)->GetType()
870 #define IDirect3DCubeTexture8_SetLOD(p,a) (p)->SetLOD(a)
871 #define IDirect3DCubeTexture8_GetLOD(p) (p)->GetLOD()
872 #define IDirect3DCubeTexture8_GetLevelCount(p) (p)->GetLevelCount()
873 #define IDirect3DCubeTexture8_GetLevelDesc(p,a,b) (p)->GetLevelDesc(a,b)
874 #define IDirect3DCubeTexture8_GetCubeMapSurface(p,a,b,c) (p)->GetCubeMapSurface(a,b,c)
875 #define IDirect3DCubeTexture8_LockRect(p,a,b,c,d,e) (p)->LockRect(a,b,c,d,e)
876 #define IDirect3DCubeTexture8_UnlockRect(p,a,b) (p)->UnlockRect(a,b)
877 #define IDirect3DCubeTexture8_AddDirtyRect(p,a,b) (p)->AddDirtyRect(a,b)
878 #endif
879 
880 #undef INTERFACE
881 #define INTERFACE IDirect3DVertexBuffer8
882 
DECLARE_INTERFACE_(IDirect3DVertexBuffer8,IDirect3DResource8)883 DECLARE_INTERFACE_(IDirect3DVertexBuffer8, IDirect3DResource8)
884 {
885     /*** IUnknown methods ***/
886     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
887     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
888     STDMETHOD_(ULONG,Release)(THIS) PURE;
889 
890     /*** IDirect3DResource8 methods ***/
891     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE;
892     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
893     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
894     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
895     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
896     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
897     STDMETHOD_(void, PreLoad)(THIS) PURE;
898     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
899     STDMETHOD(Lock)(THIS_ UINT OffsetToLock,UINT SizeToLock,BYTE** ppbData,DWORD Flags) PURE;
900     STDMETHOD(Unlock)(THIS) PURE;
901     STDMETHOD(GetDesc)(THIS_ D3DVERTEXBUFFER_DESC *pDesc) PURE;
902 };
903 
904 typedef struct IDirect3DVertexBuffer8 *LPDIRECT3DVERTEXBUFFER8, *PDIRECT3DVERTEXBUFFER8;
905 
906 #if !defined(__cplusplus) || defined(CINTERFACE)
907 #define IDirect3DVertexBuffer8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
908 #define IDirect3DVertexBuffer8_AddRef(p) (p)->lpVtbl->AddRef(p)
909 #define IDirect3DVertexBuffer8_Release(p) (p)->lpVtbl->Release(p)
910 #define IDirect3DVertexBuffer8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
911 #define IDirect3DVertexBuffer8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
912 #define IDirect3DVertexBuffer8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
913 #define IDirect3DVertexBuffer8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
914 #define IDirect3DVertexBuffer8_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
915 #define IDirect3DVertexBuffer8_GetPriority(p) (p)->lpVtbl->GetPriority(p)
916 #define IDirect3DVertexBuffer8_PreLoad(p) (p)->lpVtbl->PreLoad(p)
917 #define IDirect3DVertexBuffer8_GetType(p) (p)->lpVtbl->GetType(p)
918 #define IDirect3DVertexBuffer8_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d)
919 #define IDirect3DVertexBuffer8_Unlock(p) (p)->lpVtbl->Unlock(p)
920 #define IDirect3DVertexBuffer8_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a)
921 #else
922 #define IDirect3DVertexBuffer8_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
923 #define IDirect3DVertexBuffer8_AddRef(p) (p)->AddRef()
924 #define IDirect3DVertexBuffer8_Release(p) (p)->Release()
925 #define IDirect3DVertexBuffer8_GetDevice(p,a) (p)->GetDevice(a)
926 #define IDirect3DVertexBuffer8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
927 #define IDirect3DVertexBuffer8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
928 #define IDirect3DVertexBuffer8_FreePrivateData(p,a) (p)->FreePrivateData(a)
929 #define IDirect3DVertexBuffer8_SetPriority(p,a) (p)->SetPriority(a)
930 #define IDirect3DVertexBuffer8_GetPriority(p) (p)->GetPriority()
931 #define IDirect3DVertexBuffer8_PreLoad(p) (p)->PreLoad()
932 #define IDirect3DVertexBuffer8_GetType(p) (p)->GetType()
933 #define IDirect3DVertexBuffer8_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d)
934 #define IDirect3DVertexBuffer8_Unlock(p) (p)->Unlock()
935 #define IDirect3DVertexBuffer8_GetDesc(p,a) (p)->GetDesc(a)
936 #endif
937 
938 #undef INTERFACE
939 #define INTERFACE IDirect3DIndexBuffer8
940 
DECLARE_INTERFACE_(IDirect3DIndexBuffer8,IDirect3DResource8)941 DECLARE_INTERFACE_(IDirect3DIndexBuffer8, IDirect3DResource8)
942 {
943     /*** IUnknown methods ***/
944     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
945     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
946     STDMETHOD_(ULONG,Release)(THIS) PURE;
947 
948     /*** IDirect3DResource8 methods ***/
949     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE;
950     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
951     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
952     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
953     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
954     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
955     STDMETHOD_(void, PreLoad)(THIS) PURE;
956     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
957     STDMETHOD(Lock)(THIS_ UINT OffsetToLock,UINT SizeToLock,BYTE** ppbData,DWORD Flags) PURE;
958     STDMETHOD(Unlock)(THIS) PURE;
959     STDMETHOD(GetDesc)(THIS_ D3DINDEXBUFFER_DESC *pDesc) PURE;
960 };
961 
962 typedef struct IDirect3DIndexBuffer8 *LPDIRECT3DINDEXBUFFER8, *PDIRECT3DINDEXBUFFER8;
963 
964 #if !defined(__cplusplus) || defined(CINTERFACE)
965 #define IDirect3DIndexBuffer8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
966 #define IDirect3DIndexBuffer8_AddRef(p) (p)->lpVtbl->AddRef(p)
967 #define IDirect3DIndexBuffer8_Release(p) (p)->lpVtbl->Release(p)
968 #define IDirect3DIndexBuffer8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
969 #define IDirect3DIndexBuffer8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
970 #define IDirect3DIndexBuffer8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
971 #define IDirect3DIndexBuffer8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
972 #define IDirect3DIndexBuffer8_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
973 #define IDirect3DIndexBuffer8_GetPriority(p) (p)->lpVtbl->GetPriority(p)
974 #define IDirect3DIndexBuffer8_PreLoad(p) (p)->lpVtbl->PreLoad(p)
975 #define IDirect3DIndexBuffer8_GetType(p) (p)->lpVtbl->GetType(p)
976 #define IDirect3DIndexBuffer8_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d)
977 #define IDirect3DIndexBuffer8_Unlock(p) (p)->lpVtbl->Unlock(p)
978 #define IDirect3DIndexBuffer8_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a)
979 #else
980 #define IDirect3DIndexBuffer8_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
981 #define IDirect3DIndexBuffer8_AddRef(p) (p)->AddRef()
982 #define IDirect3DIndexBuffer8_Release(p) (p)->Release()
983 #define IDirect3DIndexBuffer8_GetDevice(p,a) (p)->GetDevice(a)
984 #define IDirect3DIndexBuffer8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
985 #define IDirect3DIndexBuffer8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
986 #define IDirect3DIndexBuffer8_FreePrivateData(p,a) (p)->FreePrivateData(a)
987 #define IDirect3DIndexBuffer8_SetPriority(p,a) (p)->SetPriority(a)
988 #define IDirect3DIndexBuffer8_GetPriority(p) (p)->GetPriority()
989 #define IDirect3DIndexBuffer8_PreLoad(p) (p)->PreLoad()
990 #define IDirect3DIndexBuffer8_GetType(p) (p)->GetType()
991 #define IDirect3DIndexBuffer8_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d)
992 #define IDirect3DIndexBuffer8_Unlock(p) (p)->Unlock()
993 #define IDirect3DIndexBuffer8_GetDesc(p,a) (p)->GetDesc(a)
994 #endif
995 
996 #undef INTERFACE
997 #define INTERFACE IDirect3DSurface8
998 
DECLARE_INTERFACE_(IDirect3DSurface8,IUnknown)999 DECLARE_INTERFACE_(IDirect3DSurface8, IUnknown)
1000 {
1001     /*** IUnknown methods ***/
1002     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
1003     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
1004     STDMETHOD_(ULONG,Release)(THIS) PURE;
1005 
1006     /*** IDirect3DSurface8 methods ***/
1007     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE;
1008     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
1009     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
1010     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
1011     STDMETHOD(GetContainer)(THIS_ REFIID riid,void** ppContainer) PURE;
1012     STDMETHOD(GetDesc)(THIS_ D3DSURFACE_DESC *pDesc) PURE;
1013     STDMETHOD(LockRect)(THIS_ D3DLOCKED_RECT* pLockedRect,CONST RECT* pRect,DWORD Flags) PURE;
1014     STDMETHOD(UnlockRect)(THIS) PURE;
1015 };
1016 
1017 typedef struct IDirect3DSurface8 *LPDIRECT3DSURFACE8, *PDIRECT3DSURFACE8;
1018 
1019 #if !defined(__cplusplus) || defined(CINTERFACE)
1020 #define IDirect3DSurface8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
1021 #define IDirect3DSurface8_AddRef(p) (p)->lpVtbl->AddRef(p)
1022 #define IDirect3DSurface8_Release(p) (p)->lpVtbl->Release(p)
1023 #define IDirect3DSurface8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
1024 #define IDirect3DSurface8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
1025 #define IDirect3DSurface8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
1026 #define IDirect3DSurface8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
1027 #define IDirect3DSurface8_GetContainer(p,a,b) (p)->lpVtbl->GetContainer(p,a,b)
1028 #define IDirect3DSurface8_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a)
1029 #define IDirect3DSurface8_LockRect(p,a,b,c) (p)->lpVtbl->LockRect(p,a,b,c)
1030 #define IDirect3DSurface8_UnlockRect(p) (p)->lpVtbl->UnlockRect(p)
1031 #else
1032 #define IDirect3DSurface8_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
1033 #define IDirect3DSurface8_AddRef(p) (p)->AddRef()
1034 #define IDirect3DSurface8_Release(p) (p)->Release()
1035 #define IDirect3DSurface8_GetDevice(p,a) (p)->GetDevice(a)
1036 #define IDirect3DSurface8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
1037 #define IDirect3DSurface8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
1038 #define IDirect3DSurface8_FreePrivateData(p,a) (p)->FreePrivateData(a)
1039 #define IDirect3DSurface8_GetContainer(p,a,b) (p)->GetContainer(a,b)
1040 #define IDirect3DSurface8_GetDesc(p,a) (p)->GetDesc(a)
1041 #define IDirect3DSurface8_LockRect(p,a,b,c) (p)->LockRect(a,b,c)
1042 #define IDirect3DSurface8_UnlockRect(p) (p)->UnlockRect()
1043 #endif
1044 
1045 #undef INTERFACE
1046 #define INTERFACE IDirect3DVolume8
1047 
DECLARE_INTERFACE_(IDirect3DVolume8,IUnknown)1048 DECLARE_INTERFACE_(IDirect3DVolume8, IUnknown)
1049 {
1050     /*** IUnknown methods ***/
1051     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
1052     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
1053     STDMETHOD_(ULONG,Release)(THIS) PURE;
1054 
1055     /*** IDirect3DVolume8 methods ***/
1056     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE;
1057     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
1058     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
1059     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
1060     STDMETHOD(GetContainer)(THIS_ REFIID riid,void** ppContainer) PURE;
1061     STDMETHOD(GetDesc)(THIS_ D3DVOLUME_DESC *pDesc) PURE;
1062     STDMETHOD(LockBox)(THIS_ D3DLOCKED_BOX * pLockedVolume,CONST D3DBOX* pBox,DWORD Flags) PURE;
1063     STDMETHOD(UnlockBox)(THIS) PURE;
1064 };
1065 
1066 typedef struct IDirect3DVolume8 *LPDIRECT3DVOLUME8, *PDIRECT3DVOLUME8;
1067 
1068 #if !defined(__cplusplus) || defined(CINTERFACE)
1069 #define IDirect3DVolume8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
1070 #define IDirect3DVolume8_AddRef(p) (p)->lpVtbl->AddRef(p)
1071 #define IDirect3DVolume8_Release(p) (p)->lpVtbl->Release(p)
1072 #define IDirect3DVolume8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
1073 #define IDirect3DVolume8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
1074 #define IDirect3DVolume8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
1075 #define IDirect3DVolume8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
1076 #define IDirect3DVolume8_GetContainer(p,a,b) (p)->lpVtbl->GetContainer(p,a,b)
1077 #define IDirect3DVolume8_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a)
1078 #define IDirect3DVolume8_LockBox(p,a,b,c) (p)->lpVtbl->LockBox(p,a,b,c)
1079 #define IDirect3DVolume8_UnlockBox(p) (p)->lpVtbl->UnlockBox(p)
1080 #else
1081 #define IDirect3DVolume8_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
1082 #define IDirect3DVolume8_AddRef(p) (p)->AddRef()
1083 #define IDirect3DVolume8_Release(p) (p)->Release()
1084 #define IDirect3DVolume8_GetDevice(p,a) (p)->GetDevice(a)
1085 #define IDirect3DVolume8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
1086 #define IDirect3DVolume8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
1087 #define IDirect3DVolume8_FreePrivateData(p,a) (p)->FreePrivateData(a)
1088 #define IDirect3DVolume8_GetContainer(p,a,b) (p)->GetContainer(a,b)
1089 #define IDirect3DVolume8_GetDesc(p,a) (p)->GetDesc(a)
1090 #define IDirect3DVolume8_LockBox(p,a,b,c) (p)->LockBox(a,b,c)
1091 #define IDirect3DVolume8_UnlockBox(p) (p)->UnlockBox()
1092 #endif
1093 
1094 /****************************************************************************
1095  * Flags for SetPrivateData method on all D3D8 interfaces
1096  *
1097  * The passed pointer is an IUnknown ptr. The SizeOfData argument to SetPrivateData
1098  * must be set to sizeof(IUnknown*). Direct3D will call AddRef through this
1099  * pointer and Release when the private data is destroyed. The data will be
1100  * destroyed when another SetPrivateData with the same GUID is set, when
1101  * FreePrivateData is called, or when the D3D8 object is freed.
1102  ****************************************************************************/
1103 #define D3DSPD_IUNKNOWN                         0x00000001L
1104 
1105 /****************************************************************************
1106  *
1107  * Parameter for IDirect3D8 Enum and GetCaps8 functions to get the info for
1108  * the current mode only.
1109  *
1110  ****************************************************************************/
1111 
1112 #define D3DCURRENT_DISPLAY_MODE                 0x00EFFFFFL
1113 
1114 /****************************************************************************
1115  *
1116  * Flags for IDirect3D8::CreateDevice's BehaviorFlags
1117  *
1118  ****************************************************************************/
1119 
1120 #define D3DCREATE_FPU_PRESERVE                  0x00000002L
1121 #define D3DCREATE_MULTITHREADED                 0x00000004L
1122 
1123 #define D3DCREATE_PUREDEVICE                    0x00000010L
1124 #define D3DCREATE_SOFTWARE_VERTEXPROCESSING     0x00000020L
1125 #define D3DCREATE_HARDWARE_VERTEXPROCESSING     0x00000040L
1126 #define D3DCREATE_MIXED_VERTEXPROCESSING        0x00000080L
1127 
1128 #define D3DCREATE_DISABLE_DRIVER_MANAGEMENT     0x00000100L
1129 
1130 /****************************************************************************
1131  *
1132  * Parameter for IDirect3D8::CreateDevice's iAdapter
1133  *
1134  ****************************************************************************/
1135 
1136 #define D3DADAPTER_DEFAULT                     0
1137 
1138 /****************************************************************************
1139  *
1140  * Flags for IDirect3D8::EnumAdapters
1141  *
1142  ****************************************************************************/
1143 
1144 #define D3DENUM_NO_WHQL_LEVEL                   0x00000002L
1145 
1146 /****************************************************************************
1147  *
1148  * Maximum number of back-buffers supported in DX8
1149  *
1150  ****************************************************************************/
1151 
1152 #define D3DPRESENT_BACK_BUFFERS_MAX             3L
1153 
1154 /****************************************************************************
1155  *
1156  * Flags for IDirect3DDevice8::SetGammaRamp
1157  *
1158  ****************************************************************************/
1159 
1160 #define D3DSGR_NO_CALIBRATION                  0x00000000L
1161 #define D3DSGR_CALIBRATE                       0x00000001L
1162 
1163 /****************************************************************************
1164  *
1165  * Flags for IDirect3DDevice8::SetCursorPosition
1166  *
1167  ****************************************************************************/
1168 
1169 #define D3DCURSOR_IMMEDIATE_UPDATE             0x00000001L
1170 
1171 /****************************************************************************
1172  *
1173  * Flags for DrawPrimitive/DrawIndexedPrimitive
1174  *   Also valid for Begin/BeginIndexed
1175  *   Also valid for VertexBuffer::CreateVertexBuffer
1176  ****************************************************************************/
1177 
1178 /*
1179  *  DirectDraw error codes
1180  */
1181 #define _FACD3D  0x876
1182 #define MAKE_D3DHRESULT( code )  MAKE_HRESULT( 1, _FACD3D, code )
1183 
1184 /*
1185  * Direct3D Errors
1186  */
1187 #define D3D_OK                              S_OK
1188 
1189 #define D3DERR_WRONGTEXTUREFORMAT               MAKE_D3DHRESULT(2072)
1190 #define D3DERR_UNSUPPORTEDCOLOROPERATION        MAKE_D3DHRESULT(2073)
1191 #define D3DERR_UNSUPPORTEDCOLORARG              MAKE_D3DHRESULT(2074)
1192 #define D3DERR_UNSUPPORTEDALPHAOPERATION        MAKE_D3DHRESULT(2075)
1193 #define D3DERR_UNSUPPORTEDALPHAARG              MAKE_D3DHRESULT(2076)
1194 #define D3DERR_TOOMANYOPERATIONS                MAKE_D3DHRESULT(2077)
1195 #define D3DERR_CONFLICTINGTEXTUREFILTER         MAKE_D3DHRESULT(2078)
1196 #define D3DERR_UNSUPPORTEDFACTORVALUE           MAKE_D3DHRESULT(2079)
1197 #define D3DERR_CONFLICTINGRENDERSTATE           MAKE_D3DHRESULT(2081)
1198 #define D3DERR_UNSUPPORTEDTEXTUREFILTER         MAKE_D3DHRESULT(2082)
1199 #define D3DERR_CONFLICTINGTEXTUREPALETTE        MAKE_D3DHRESULT(2086)
1200 #define D3DERR_DRIVERINTERNALERROR              MAKE_D3DHRESULT(2087)
1201 
1202 #define D3DERR_NOTFOUND                         MAKE_D3DHRESULT(2150)
1203 #define D3DERR_MOREDATA                         MAKE_D3DHRESULT(2151)
1204 #define D3DERR_DEVICELOST                       MAKE_D3DHRESULT(2152)
1205 #define D3DERR_DEVICENOTRESET                   MAKE_D3DHRESULT(2153)
1206 #define D3DERR_NOTAVAILABLE                     MAKE_D3DHRESULT(2154)
1207 #define D3DERR_OUTOFVIDEOMEMORY                 MAKE_D3DHRESULT(380)
1208 #define D3DERR_INVALIDDEVICE                    MAKE_D3DHRESULT(2155)
1209 #define D3DERR_INVALIDCALL                      MAKE_D3DHRESULT(2156)
1210 #define D3DERR_DRIVERINVALIDCALL                MAKE_D3DHRESULT(2157)
1211 
1212 #ifdef __cplusplus
1213 };
1214 #endif
1215 
1216 #endif /* (DIRECT3D_VERSION >= 0x0800) */
1217 
1218 #endif /* _D3D_H_ */
1219