2 * Direct3D wine internal public interface file
4 * Copyright 2002-2003 The wine-d3d team
5 * Copyright 2002-2003 Raphael Junqueira
7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Lesser General Public
9 * License as published by the Free Software Foundation; either
10 * version 2.1 of the License, or (at your option) any later version.
12 * This library is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * Lesser General Public License for more details.
17 * You should have received a copy of the GNU Lesser General Public
18 * License along with this library; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
22 #ifndef __WINE_WINED3D_INTERFACE_H
23 #define __WINE_WINED3D_INTERFACE_H
25 #if !defined( __WINE_CONFIG_H )
26 # error You must include config.h to use this header
29 #if !defined( __WINE_D3D8_H ) && !defined( __WINE_D3D9_H )
30 # error You must include d3d8.h or d3d9.h header to use this header
33 /*****************************************************************
34 * THIS FILE MUST NOT CONTAIN X11 or MESA DEFINES
35 * PLEASE USE wine/wined3d_gl.h INSTEAD
39 /*****************************************************************************
40 * WineD3D Structures to be used when d3d8 and d3d9 are incompatible
42 typedef struct _WINED3DADAPTER_IDENTIFIER {
46 LARGE_INTEGER *DriverVersion;
51 GUID *DeviceIdentifier;
53 } WINED3DADAPTER_IDENTIFIER;
55 typedef struct _WINED3DPRESENT_PARAMETERS {
56 UINT *BackBufferWidth;
57 UINT *BackBufferHeight;
58 D3DFORMAT *BackBufferFormat;
59 UINT *BackBufferCount;
60 D3DMULTISAMPLE_TYPE *MultiSampleType;
61 DWORD *MultiSampleQuality;
62 D3DSWAPEFFECT *SwapEffect;
65 BOOL *EnableAutoDepthStencil;
66 D3DFORMAT *AutoDepthStencilFormat;
68 UINT *FullScreen_RefreshRateInHz;
69 UINT *PresentationInterval;
70 } WINED3DPRESENT_PARAMETERS;
72 typedef struct _WINED3DSURFACE_DESC
75 D3DRESOURCETYPE *Type;
80 D3DMULTISAMPLE_TYPE *MultiSampleType;
81 DWORD *MultiSampleQuality;
84 } WINED3DSURFACE_DESC;
86 typedef struct _WINED3DVOLUME_DESC
89 D3DRESOURCETYPE *Type;
99 /* The following have differing names, but actually are the same layout. */
100 /* Also, D3DCAPS8 is a subset of D3DCAPS9 so can be typecase as long as
101 none of the 9 fields are accessed when the device is d3d8 */
102 #if defined( __WINE_D3D8_H )
104 #define WINED3DLIGHT D3DLIGHT8
105 #define WINED3DCLIPSTATUS D3DCLIPSTATUS8
106 #define WINED3DMATERIAL D3DMATERIAL8
107 #define WINED3DVIEWPORT D3DVIEWPORT8
110 #define WINED3DCAPS D3DCAPS8
113 #define WINED3DLIGHT D3DLIGHT9
114 #define WINED3DCLIPSTATUS D3DCLIPSTATUS9
115 #define WINED3DMATERIAL D3DMATERIAL9
116 #define WINED3DVIEWPORT D3DVIEWPORT9
119 #define WINED3DCAPS D3DCAPS9
122 typedef struct IWineD3D IWineD3D;
123 typedef struct IWineD3DDevice IWineD3DDevice;
124 typedef struct IWineD3DResource IWineD3DResource;
125 typedef struct IWineD3DVertexBuffer IWineD3DVertexBuffer;
126 typedef struct IWineD3DIndexBuffer IWineD3DIndexBuffer;
127 typedef struct IWineD3DBaseTexture IWineD3DBaseTexture;
128 typedef struct IWineD3DTexture IWineD3DTexture;
129 typedef struct IWineD3DCubeTexture IWineD3DCubeTexture;
130 typedef struct IWineD3DVolumeTexture IWineD3DVolumeTexture;
131 typedef struct IWineD3DStateBlock IWineD3DStateBlock;
132 typedef struct IWineD3DSurface IWineD3DSurface;
133 typedef struct IWineD3DVolume IWineD3DVolume;
134 typedef struct IWineD3DVertexDeclaration IWineD3DVertexDeclaration;
135 typedef struct IWineD3DVertexShader IWineD3DVertexShader;
136 typedef struct IWineD3DPixelShader IWineD3DPixelShader;
138 /*****************************************************************************
139 * Callback functions required for predefining surfaces / stencils
141 typedef HRESULT WINAPI (*D3DCB_CREATERENDERTARGETFN) (IUnknown *pDevice,
145 D3DMULTISAMPLE_TYPE MultiSample,
146 DWORD MultisampleQuality,
148 IWineD3DSurface **ppSurface,
149 HANDLE * pSharedHandle);
151 typedef HRESULT WINAPI (*D3DCB_CREATESURFACEFN) (IUnknown *pDevice,
156 IWineD3DSurface **ppSurface,
157 HANDLE * pSharedHandle);
159 typedef HRESULT WINAPI (*D3DCB_CREATEVOLUMEFN) (IUnknown *pDevice,
166 IWineD3DVolume **ppVolume,
167 HANDLE * pSharedHandle);
169 /*****************************************************************************
173 #define INTERFACE IWineD3D
174 DECLARE_INTERFACE_(IWineD3D,IUnknown)
176 /*** IUnknown methods ***/
177 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
178 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
179 STDMETHOD_(ULONG,Release)(THIS) PURE;
180 /*** IWineD3D methods ***/
181 STDMETHOD(GetParent)(THIS_ IUnknown **pParent) PURE;
182 STDMETHOD_(UINT,GetAdapterCount)(THIS) PURE;
183 STDMETHOD(RegisterSoftwareDevice)(THIS_ void * pInitializeFunction) PURE;
184 STDMETHOD_(HMONITOR,GetAdapterMonitor)(THIS_ UINT Adapter) PURE;
185 STDMETHOD_(UINT,GetAdapterModeCount)(THIS_ UINT Adapter, D3DFORMAT Format) PURE;
186 STDMETHOD(EnumAdapterModes)(THIS_ UINT Adapter, UINT Mode, D3DFORMAT Format, D3DDISPLAYMODE * pMode) PURE;
187 STDMETHOD(GetAdapterDisplayMode)(THIS_ UINT Adapter, D3DDISPLAYMODE * pMode) PURE;
188 STDMETHOD(GetAdapterIdentifier)(THIS_ UINT Adapter, DWORD Flags, WINED3DADAPTER_IDENTIFIER* pIdentifier) PURE;
189 STDMETHOD(CheckDeviceMultiSampleType)(THIS_ UINT Adapter, D3DDEVTYPE DeviceType, D3DFORMAT SurfaceFormat, BOOL Windowed, D3DMULTISAMPLE_TYPE MultiSampleType, DWORD *pQuality) PURE;
190 STDMETHOD(CheckDepthStencilMatch)(THIS_ UINT Adapter, D3DDEVTYPE DeviceType, D3DFORMAT AdapterFormat, D3DFORMAT RenderTargetFormat, D3DFORMAT DepthStencilFormat) PURE;
191 STDMETHOD(CheckDeviceType)(THIS_ UINT Adapter, D3DDEVTYPE CheckType, D3DFORMAT DisplayFormat, D3DFORMAT BackBufferFormat, BOOL Windowed) PURE;
192 STDMETHOD(CheckDeviceFormat)(THIS_ UINT Adapter, D3DDEVTYPE DeviceType, D3DFORMAT AdapterFormat, DWORD Usage, D3DRESOURCETYPE RType, D3DFORMAT CheckFormat) PURE;
193 STDMETHOD(CheckDeviceFormatConversion)(THIS_ UINT Adapter, D3DDEVTYPE DeviceType, D3DFORMAT SourceFormat, D3DFORMAT TargetFormat) PURE;
194 STDMETHOD(GetDeviceCaps)(THIS_ UINT Adapter, D3DDEVTYPE DeviceType, WINED3DCAPS* pCaps) PURE;
195 STDMETHOD(CreateDevice)(THIS_ UINT Adapter, D3DDEVTYPE DeviceType,HWND hFocusWindow, DWORD BehaviorFlags, WINED3DPRESENT_PARAMETERS * pPresentationParameters, IWineD3DDevice ** ppReturnedDeviceInterface, IUnknown *parent, D3DCB_CREATERENDERTARGETFN pFn) PURE;
199 #if !defined(__cplusplus) || defined(CINTERFACE)
200 /*** IUnknown methods ***/
201 #define IWineD3D_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
202 #define IWineD3D_AddRef(p) (p)->lpVtbl->AddRef(p)
203 #define IWineD3D_Release(p) (p)->lpVtbl->Release(p)
204 /*** IWineD3D methods ***/
205 #define IWineD3D_GetParent(p,a) (p)->lpVtbl->GetParent(p,a)
206 #define IWineD3D_GetAdapterCount(p) (p)->lpVtbl->GetAdapterCount(p)
207 #define IWineD3D_RegisterSoftwareDevice(p,a) (p)->lpVtbl->RegisterSoftwareDevice(p,a)
208 #define IWineD3D_GetAdapterMonitor(p,a) (p)->lpVtbl->GetAdapterMonitor(p,a)
209 #define IWineD3D_GetAdapterModeCount(p,a,b) (p)->lpVtbl->GetAdapterModeCount(p,a,b)
210 #define IWineD3D_EnumAdapterModes(p,a,b,c,d) (p)->lpVtbl->EnumAdapterModes(p,a,b,c,d)
211 #define IWineD3D_GetAdapterDisplayMode(p,a,b) (p)->lpVtbl->GetAdapterDisplayMode(p,a,b)
212 #define IWineD3D_GetAdapterIdentifier(p,a,b,c) (p)->lpVtbl->GetAdapterIdentifier(p,a,b,c)
213 #define IWineD3D_CheckDeviceMultiSampleType(p,a,b,c,d,e,f) (p)->lpVtbl->CheckDeviceMultiSampleType(p,a,b,c,d,e,f)
214 #define IWineD3D_CheckDepthStencilMatch(p,a,b,c,d,e) (p)->lpVtbl->CheckDepthStencilMatch(p,a,b,c,d,e)
215 #define IWineD3D_CheckDeviceType(p,a,b,c,d,e) (p)->lpVtbl->CheckDeviceType(p,a,b,c,d,e)
216 #define IWineD3D_CheckDeviceFormat(p,a,b,c,d,e,f) (p)->lpVtbl->CheckDeviceFormat(p,a,b,c,d,e,f)
217 #define IWineD3D_CheckDeviceFormatConversion(p,a,b,c,d) (p)->lpVtbl->CheckDeviceFormatConversion(p,a,b,c,d)
218 #define IWineD3D_GetDeviceCaps(p,a,b,c) (p)->lpVtbl->GetDeviceCaps(p,a,b,c)
219 #define IWineD3D_CreateDevice(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->CreateDevice(p,a,b,c,d,e,f,g,h)
222 /* Define the main WineD3D entrypoint */
223 IWineD3D* WINAPI WineDirect3DCreate(UINT SDKVersion, UINT dxVersion, IUnknown *parent);
225 /*****************************************************************************
226 * IWineD3DDevice interface
228 #define INTERFACE IWineD3DDevice
229 DECLARE_INTERFACE_(IWineD3DDevice,IUnknown)
231 /*** IUnknown methods ***/
232 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
233 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
234 STDMETHOD_(ULONG,Release)(THIS) PURE;
235 /*** IWineD3DDevice methods ***/
236 STDMETHOD(GetParent)(THIS_ IUnknown **pParent) PURE;
237 STDMETHOD(CreateVertexBuffer)(THIS_ UINT Length,DWORD Usage,DWORD FVF,D3DPOOL Pool,IWineD3DVertexBuffer **ppVertexBuffer, HANDLE *sharedHandle, IUnknown *parent) PURE;
238 STDMETHOD(CreateIndexBuffer)(THIS_ UINT Length, DWORD Usage, D3DFORMAT Format, D3DPOOL Pool, IWineD3DIndexBuffer** ppIndexBuffer, HANDLE* pSharedHandle, IUnknown *parent) PURE;
239 STDMETHOD(CreateStateBlock)(THIS_ D3DSTATEBLOCKTYPE Type, IWineD3DStateBlock **ppStateBlock, IUnknown *parent) PURE;
240 STDMETHOD(CreateRenderTarget)(THIS_ UINT Width, UINT Height, D3DFORMAT Format, D3DMULTISAMPLE_TYPE MultiSample, DWORD MultisampleQuality, BOOL Lockable, IWineD3DSurface** ppSurface, HANDLE* pSharedHandle, IUnknown *parent) PURE;
241 STDMETHOD(CreateOffscreenPlainSurface)(THIS_ UINT Width, UINT Height, D3DFORMAT Format, D3DPOOL Pool, IWineD3DSurface** ppSurface, HANDLE* pSharedHandle, IUnknown *parent) PURE;
242 STDMETHOD(CreateTexture)(THIS_ UINT Width, UINT Height, UINT Levels, DWORD Usage, D3DFORMAT Format, D3DPOOL Pool, IWineD3DTexture** ppTexture, HANDLE* pSharedHandle, IUnknown *parent, D3DCB_CREATESURFACEFN pFn) PURE;
243 STDMETHOD(CreateVolumeTexture)(THIS_ UINT Width, UINT Height, UINT Depth, UINT Levels, DWORD Usage, D3DFORMAT Format, D3DPOOL Pool, IWineD3DVolumeTexture** ppVolumeTexture, HANDLE* pSharedHandle, IUnknown *parent, D3DCB_CREATEVOLUMEFN pFn) PURE;
244 STDMETHOD(CreateVolume)(THIS_ UINT Width, UINT Height, UINT Depth, DWORD Usage, D3DFORMAT Format, D3DPOOL Pool, IWineD3DVolume** ppVolumeTexture, HANDLE* pSharedHandle, IUnknown *parent) PURE;
245 STDMETHOD(CreateCubeTexture)(THIS_ UINT EdgeLength, UINT Levels, DWORD Usage, D3DFORMAT Format, D3DPOOL Pool, IWineD3DCubeTexture** ppCubeTexture, HANDLE* pSharedHandle, IUnknown *parent, D3DCB_CREATESURFACEFN pFn) PURE;
246 STDMETHOD(SetFVF)(THIS_ DWORD fvf) PURE;
247 STDMETHOD(GetFVF)(THIS_ DWORD * pfvf) PURE;
248 STDMETHOD(SetStreamSource)(THIS_ UINT StreamNumber,IWineD3DVertexBuffer * pStreamData,UINT Offset,UINT Stride) PURE;
249 STDMETHOD(GetStreamSource)(THIS_ UINT StreamNumber,IWineD3DVertexBuffer ** ppStreamData,UINT *pOffset, UINT * pStride) PURE;
250 STDMETHOD(SetTransform)(THIS_ D3DTRANSFORMSTATETYPE State,CONST D3DMATRIX * pMatrix) PURE;
251 STDMETHOD(GetTransform)(THIS_ D3DTRANSFORMSTATETYPE State,D3DMATRIX * pMatrix) PURE;
252 STDMETHOD(MultiplyTransform)(THIS_ D3DTRANSFORMSTATETYPE State, CONST D3DMATRIX * pMatrix) PURE;
253 STDMETHOD(SetLight)(THIS_ DWORD Index,CONST WINED3DLIGHT * pLight) PURE;
254 STDMETHOD(GetLight)(THIS_ DWORD Index,WINED3DLIGHT * pLight) PURE;
255 STDMETHOD(SetLightEnable)(THIS_ DWORD Index,BOOL Enable) PURE;
256 STDMETHOD(GetLightEnable)(THIS_ DWORD Index,BOOL * pEnable) PURE;
257 STDMETHOD(SetClipPlane)(THIS_ DWORD Index,CONST float * pPlane) PURE;
258 STDMETHOD(GetClipPlane)(THIS_ DWORD Index,float * pPlane) PURE;
259 STDMETHOD(SetClipStatus)(THIS_ CONST WINED3DCLIPSTATUS * pClipStatus) PURE;
260 STDMETHOD(GetClipStatus)(THIS_ WINED3DCLIPSTATUS * pClipStatus) PURE;
261 STDMETHOD(SetMaterial)(THIS_ CONST WINED3DMATERIAL * pMaterial) PURE;
262 STDMETHOD(GetMaterial)(THIS_ WINED3DMATERIAL *pMaterial) PURE;
263 STDMETHOD(SetIndices)(THIS_ IWineD3DIndexBuffer * pIndexData,UINT BaseVertexIndex) PURE;
264 STDMETHOD(GetIndices)(THIS_ IWineD3DIndexBuffer ** ppIndexData,UINT * pBaseVertexIndex) PURE;
265 STDMETHOD(SetViewport)(THIS_ CONST WINED3DVIEWPORT * pViewport) PURE;
266 STDMETHOD(GetViewport)(THIS_ WINED3DVIEWPORT * pViewport) PURE;
267 STDMETHOD(SetRenderState)(THIS_ D3DRENDERSTATETYPE State,DWORD Value) PURE;
268 STDMETHOD(GetRenderState)(THIS_ D3DRENDERSTATETYPE State,DWORD * pValue) PURE;
269 STDMETHOD(SetTextureStageState)(THIS_ DWORD Stage,D3DTEXTURESTAGESTATETYPE Type,DWORD Value) PURE;
270 STDMETHOD(GetTextureStageState)(THIS_ DWORD Stage,D3DTEXTURESTAGESTATETYPE Type,DWORD * pValue) PURE;
271 STDMETHOD(SetTexture)(THIS_ DWORD Stage, IWineD3DBaseTexture* pTexture) PURE;
272 STDMETHOD(GetTexture)(THIS_ DWORD Stage, IWineD3DBaseTexture** ppTexture) PURE;
273 STDMETHOD(GetBackBuffer)(THIS_ UINT iSwapChain, UINT iBackBuffer, D3DBACKBUFFER_TYPE Type, IWineD3DSurface** ppBackBuffer) PURE;
274 STDMETHOD(GetDeviceCaps)(THIS_ WINED3DCAPS* pCaps) PURE;
275 STDMETHOD(GetDisplayMode)(THIS_ UINT iSwapChain, D3DDISPLAYMODE* pMode) PURE;
276 STDMETHOD(BeginScene)(THIS) PURE;
277 STDMETHOD(EndScene)(THIS) PURE;
278 STDMETHOD(Present)(THIS_ CONST RECT * pSourceRect,CONST RECT * pDestRect,HWND hDestWindowOverride,CONST RGNDATA * pDirtyRegion) PURE;
279 STDMETHOD(Clear)(THIS_ DWORD Count,CONST D3DRECT * pRects,DWORD Flags,D3DCOLOR Color,float Z,DWORD Stencil) PURE;
280 STDMETHOD(DrawPrimitive)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT StartVertex,UINT PrimitiveCount) PURE;
281 STDMETHOD(DrawIndexedPrimitive)(THIS_ D3DPRIMITIVETYPE PrimitiveType,INT baseVIdx, UINT minIndex,UINT NumVertices,UINT startIndex,UINT primCount) PURE;
282 STDMETHOD(DrawPrimitiveUP)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT PrimitiveCount,CONST void * pVertexStreamZeroData,UINT VertexStreamZeroStride) PURE;
283 STDMETHOD(DrawIndexedPrimitiveUP)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT MinVertexIndex,UINT NumVertexIndices,UINT PrimitiveCount,CONST void * pIndexData,D3DFORMAT IndexDataFormat,CONST void * pVertexStreamZeroData,UINT VertexStreamZeroStride) PURE;
284 STDMETHOD(CreateVertexDeclaration)(THIS_ UINT iDeclVersion, CONST VOID* pDeclaration, IWineD3DVertexDeclaration** ppDecl) PURE;
285 STDMETHOD(SetVertexDeclaration)(THIS_ IWineD3DVertexDeclaration* pDecl) PURE;
286 STDMETHOD(GetVertexDeclaration)(THIS_ IWineD3DVertexDeclaration** ppDecl) PURE;
287 /*** Internal use IWineD3D methods ***/
288 STDMETHOD_(void, SetupTextureStates)(THIS_ DWORD Stage, DWORD Flags);
292 #if !defined(__cplusplus) || defined(CINTERFACE)
293 /*** IUnknown methods ***/
294 #define IWineD3DDevice_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
295 #define IWineD3DDevice_AddRef(p) (p)->lpVtbl->AddRef(p)
296 #define IWineD3DDevice_Release(p) (p)->lpVtbl->Release(p)
297 /*** IWineD3DDevice methods ***/
298 #define IWineD3DDevice_GetParent(p,a) (p)->lpVtbl->GetParent(p,a)
299 #define IWineD3DDevice_CreateVertexBuffer(p,a,b,c,d,e,f,g) (p)->lpVtbl->CreateVertexBuffer(p,a,b,c,d,e,f,g)
300 #define IWineD3DDevice_CreateIndexBuffer(p,a,b,c,d,e,f,g) (p)->lpVtbl->CreateIndexBuffer(p,a,b,c,d,e,f,g)
301 #define IWineD3DDevice_CreateStateBlock(p,a,b,c) (p)->lpVtbl->CreateStateBlock(p,a,b,c)
302 #define IWineD3DDevice_CreateRenderTarget(p,a,b,c,d,e,f,g,h,i) (p)->lpVtbl->CreateRenderTarget(p,a,b,c,d,e,f,g,h,i)
303 #define IWineD3DDevice_CreateOffscreenPlainSurface(p,a,b,c,d,e,f,g) (p)->lpVtbl->CreateOffscreenPlainSurface(p,a,b,c,d,e,f,g)
304 #define IWineD3DDevice_CreateTexture(p,a,b,c,d,e,f,g,h,i,j) (p)->lpVtbl->CreateTexture(p,a,b,c,d,e,f,g,h,i,j)
305 #define IWineD3DDevice_CreateVolumeTexture(p,a,b,c,d,e,f,g,h,i,j,k) (p)->lpVtbl->CreateVolumeTexture(p,a,b,c,d,e,f,g,h,i,j,k)
306 #define IWineD3DDevice_CreateVolume(p,a,b,c,d,e,f,g,h,i) (p)->lpVtbl->CreateVolume(p,a,b,c,d,e,f,g,h,i)
307 #define IWineD3DDevice_CreateCubeTexture(p,a,b,c,d,e,f,g,h,i) (p)->lpVtbl->CreateCubeTexture(p,a,b,c,d,e,f,g,h,i)
308 #define IWineD3DDevice_SetFVF(p,a) (p)->lpVtbl->SetFVF(p,a)
309 #define IWineD3DDevice_GetFVF(p,a) (p)->lpVtbl->GetFVF(p,a)
310 #define IWineD3DDevice_SetStreamSource(p,a,b,c,d) (p)->lpVtbl->SetStreamSource(p,a,b,c,d)
311 #define IWineD3DDevice_GetStreamSource(p,a,b,c,d) (p)->lpVtbl->GetStreamSource(p,a,b,c,d)
312 #define IWineD3DDevice_SetTransform(p,a,b) (p)->lpVtbl->SetTransform(p,a,b)
313 #define IWineD3DDevice_GetTransform(p,a,b) (p)->lpVtbl->GetTransform(p,a,b)
314 #define IWineD3DDevice_MultiplyTransform(p,a,b) (p)->lpVtbl->MultiplyTransform(p,a,b)
315 #define IWineD3DDevice_SetLight(p,a,b) (p)->lpVtbl->SetLight(p,a,b)
316 #define IWineD3DDevice_GetLight(p,a,b) (p)->lpVtbl->GetLight(p,a,b)
317 #define IWineD3DDevice_SetLightEnable(p,a,b) (p)->lpVtbl->SetLightEnable(p,a,b)
318 #define IWineD3DDevice_GetLightEnable(p,a,b) (p)->lpVtbl->GetLightEnable(p,a,b)
319 #define IWineD3DDevice_SetClipPlane(p,a,b) (p)->lpVtbl->SetClipPlane(p,a,b)
320 #define IWineD3DDevice_GetClipPlane(p,a,b) (p)->lpVtbl->GetClipPlane(p,a,b)
321 #define IWineD3DDevice_SetClipStatus(p,a) (p)->lpVtbl->SetClipStatus(p,a)
322 #define IWineD3DDevice_GetClipStatus(p,a) (p)->lpVtbl->GetClipStatus(p,a)
323 #define IWineD3DDevice_SetMaterial(p,a) (p)->lpVtbl->SetMaterial(p,a)
324 #define IWineD3DDevice_GetMaterial(p,a) (p)->lpVtbl->GetMaterial(p,a)
325 #define IWineD3DDevice_SetIndices(p,a,b) (p)->lpVtbl->SetIndices(p,a,b)
326 #define IWineD3DDevice_GetIndices(p,a,b) (p)->lpVtbl->GetIndices(p,a,b)
327 #define IWineD3DDevice_SetViewport(p,a) (p)->lpVtbl->SetViewport(p,a)
328 #define IWineD3DDevice_GetViewport(p,a) (p)->lpVtbl->GetViewport(p,a)
329 #define IWineD3DDevice_SetRenderState(p,a,b) (p)->lpVtbl->SetRenderState(p,a,b)
330 #define IWineD3DDevice_GetRenderState(p,a,b) (p)->lpVtbl->GetRenderState(p,a,b)
331 #define IWineD3DDevice_SetTextureStageState(p,a,b,c) (p)->lpVtbl->SetTextureStageState(p,a,b,c)
332 #define IWineD3DDevice_GetTextureStageState(p,a,b,c) (p)->lpVtbl->GetTextureStageState(p,a,b,c)
333 #define IWineD3DDevice_SetTexture(p,a,b) (p)->lpVtbl->SetTexture(p,a,b)
334 #define IWineD3DDevice_GetTexture(p,a,b) (p)->lpVtbl->GetTexture(p,a,b)
335 #define IWineD3DDevice_GetBackBuffer(p,a,b,c,d) (p)->lpVtbl->GetBackBuffer(p,a,b,c,d)
336 #define IWineD3DDevice_GetDeviceCaps(p,a) (p)->lpVtbl->GetDeviceCaps(p,a)
337 #define IWineD3DDevice_GetDisplayMode(p,a,b) (p)->lpVtbl->GetDisplayMode(p,a,b)
338 #define IWineD3DDevice_BeginScene(p) (p)->lpVtbl->BeginScene(p)
339 #define IWineD3DDevice_EndScene(p) (p)->lpVtbl->EndScene(p)
340 #define IWineD3DDevice_Present(p,a,b,c,d) (p)->lpVtbl->Present(p,a,b,c,d)
341 #define IWineD3DDevice_Clear(p,a,b,c,d,e,f) (p)->lpVtbl->Clear(p,a,b,c,d,e,f)
342 #define IWineD3DDevice_DrawPrimitive(p,a,b,c) (p)->lpVtbl->DrawPrimitive(p,a,b,c)
343 #define IWineD3DDevice_DrawIndexedPrimitive(p,a,b,c,d,e,f) (p)->lpVtbl->DrawIndexedPrimitive(p,a,b,c,d,e,f)
344 #define IWineD3DDevice_DrawPrimitiveUP(p,a,b,c,d) (p)->lpVtbl->DrawPrimitiveUP(p,a,b,c,d)
345 #define IWineD3DDevice_DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h)
346 #define IWineD3DDevice_CreateVertexDeclaration(p,a,b,c) (p)->lpVtbl->CreateVertexDeclaration(p,a,b,c)
347 #define IWineD3DDevice_SetVertexDeclaration(p,a) (p)->lpVtbl->SetVertexDeclaration(p,a)
348 #define IWineD3DDevice_GetVertexDeclaration(p,a) (p)->lpVtbl->GetVertexDeclaration(p,a)
349 #define IWineD3DDevice_SetupTextureStates(p,a,b) (p)->lpVtbl->SetupTextureStates(p,a,b)
352 /*****************************************************************************
353 * WineD3DResource interface
355 #define INTERFACE IWineD3DResource
356 DECLARE_INTERFACE_(IWineD3DResource,IUnknown)
358 /*** IUnknown methods ***/
359 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
360 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
361 STDMETHOD_(ULONG,Release)(THIS) PURE;
362 /*** IWineD3DResource methods ***/
363 STDMETHOD(GetParent)(THIS_ IUnknown **pParent) PURE;
364 STDMETHOD(GetDevice)(THIS_ IWineD3DDevice ** ppDevice) PURE;
365 STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid, CONST void * pData, DWORD SizeOfData, DWORD Flags) PURE;
366 STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid, void * pData, DWORD * pSizeOfData) PURE;
367 STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
368 STDMETHOD_(DWORD,SetPriority)(THIS_ DWORD PriorityNew) PURE;
369 STDMETHOD_(DWORD,GetPriority)(THIS) PURE;
370 STDMETHOD_(void,PreLoad)(THIS) PURE;
371 STDMETHOD_(D3DRESOURCETYPE,GetType)(THIS) PURE;
375 #if !defined(__cplusplus) || defined(CINTERFACE)
376 /*** IUnknown methods ***/
377 #define IWineD3DResource_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
378 #define IWineD3DResource_AddRef(p) (p)->lpVtbl->AddRef(p)
379 #define IWineD3DResource_Release(p) (p)->lpVtbl->Release(p)
380 /*** IWineD3DResource methods ***/
381 #define IWineD3DResource_GetParent(p,a) (p)->lpVtbl->GetParent(p,a)
382 #define IWineD3DResource_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
383 #define IWineD3DResource_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
384 #define IWineD3DResource_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
385 #define IWineD3DResource_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
386 #define IWineD3DResource_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
387 #define IWineD3DResource_GetPriority(p) (p)->lpVtbl->GetPriority(p)
388 #define IWineD3DResource_PreLoad(p) (p)->lpVtbl->PreLoad(p)
389 #define IWineD3DResource_GetType(p) (p)->lpVtbl->GetType(p)
392 /*****************************************************************************
393 * WineD3DVertexBuffer interface
395 #define INTERFACE IWineD3DVertexBuffer
396 DECLARE_INTERFACE_(IWineD3DVertexBuffer,IWineD3DResource)
398 /*** IUnknown methods ***/
399 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
400 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
401 STDMETHOD_(ULONG,Release)(THIS) PURE;
402 /*** IWineD3DResource methods ***/
403 STDMETHOD(GetParent)(THIS_ IUnknown **pParent) PURE;
404 STDMETHOD(GetDevice)(THIS_ IWineD3DDevice ** ppDevice) PURE;
405 STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid, CONST void * pData, DWORD SizeOfData, DWORD Flags) PURE;
406 STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid, void * pData, DWORD * pSizeOfData) PURE;
407 STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
408 STDMETHOD_(DWORD,SetPriority)(THIS_ DWORD PriorityNew) PURE;
409 STDMETHOD_(DWORD,GetPriority)(THIS) PURE;
410 STDMETHOD_(void,PreLoad)(THIS) PURE;
411 STDMETHOD_(D3DRESOURCETYPE,GetType)(THIS) PURE;
412 /*** IWineD3DVertexBuffer methods ***/
413 STDMETHOD(Lock)(THIS_ UINT OffsetToLock, UINT SizeToLock, BYTE ** ppbData, DWORD Flags) PURE;
414 STDMETHOD(Unlock)(THIS) PURE;
415 STDMETHOD(GetDesc)(THIS_ D3DVERTEXBUFFER_DESC * pDesc) PURE;
419 #if !defined(__cplusplus) || defined(CINTERFACE)
420 /*** IUnknown methods ***/
421 #define IWineD3DVertexBuffer_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
422 #define IWineD3DVertexBuffer_AddRef(p) (p)->lpVtbl->AddRef(p)
423 #define IWineD3DVertexBuffer_Release(p) (p)->lpVtbl->Release(p)
424 /*** IWineD3DResource methods ***/
425 #define IWineD3DVertexBuffer_GetParent(p,a) (p)->lpVtbl->GetParent(p,a)
426 #define IWineD3DVertexBuffer_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
427 #define IWineD3DVertexBuffer_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
428 #define IWineD3DVertexBuffer_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
429 #define IWineD3DVertexBuffer_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
430 #define IWineD3DVertexBuffer_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
431 #define IWineD3DVertexBuffer_GetPriority(p) (p)->lpVtbl->GetPriority(p)
432 #define IWineD3DVertexBuffer_PreLoad(p) (p)->lpVtbl->PreLoad(p)
433 #define IWineD3DVertexBuffer_GetType(p) (p)->lpVtbl->GetType(p)
434 /*** IWineD3DVertexBuffer methods ***/
435 #define IWineD3DVertexBuffer_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d)
436 #define IWineD3DVertexBuffer_Unlock(p) (p)->lpVtbl->Unlock(p)
437 #define IWineD3DVertexBuffer_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a)
440 /*****************************************************************************
441 * WineD3DIndexBuffer interface
443 #define INTERFACE IWineD3DIndexBuffer
444 DECLARE_INTERFACE_(IWineD3DIndexBuffer,IWineD3DResource)
446 /*** IUnknown methods ***/
447 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
448 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
449 STDMETHOD_(ULONG,Release)(THIS) PURE;
450 /*** IWineD3DResource methods ***/
451 STDMETHOD(GetParent)(THIS_ IUnknown **pParent) PURE;
452 STDMETHOD(GetDevice)(THIS_ IWineD3DDevice ** ppDevice) PURE;
453 STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid, CONST void * pData, DWORD SizeOfData, DWORD Flags) PURE;
454 STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid, void * pData, DWORD * pSizeOfData) PURE;
455 STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
456 STDMETHOD_(DWORD,SetPriority)(THIS_ DWORD PriorityNew) PURE;
457 STDMETHOD_(DWORD,GetPriority)(THIS) PURE;
458 STDMETHOD_(void,PreLoad)(THIS) PURE;
459 STDMETHOD_(D3DRESOURCETYPE,GetType)(THIS) PURE;
460 /*** IWineD3DIndexBuffer methods ***/
461 STDMETHOD(Lock)(THIS_ UINT OffsetToLock, UINT SizeToLock, BYTE ** ppbData, DWORD Flags) PURE;
462 STDMETHOD(Unlock)(THIS) PURE;
463 STDMETHOD(GetDesc)(THIS_ D3DINDEXBUFFER_DESC * pDesc) PURE;
467 #if !defined(__cplusplus) || defined(CINTERFACE)
468 /*** IUnknown methods ***/
469 #define IWineD3DIndexBuffer_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
470 #define IWineD3DIndexBuffer_AddRef(p) (p)->lpVtbl->AddRef(p)
471 #define IWineD3DIndexBuffer_Release(p) (p)->lpVtbl->Release(p)
472 /*** IWineD3DResource methods ***/
473 #define IWineD3DIndexBuffer_GetParent(p,a) (p)->lpVtbl->GetParent(p,a)
474 #define IWineD3DIndexBuffer_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
475 #define IWineD3DIndexBuffer_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
476 #define IWineD3DIndexBuffer_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
477 #define IWineD3DIndexBuffer_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
478 #define IWineD3DIndexBuffer_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
479 #define IWineD3DIndexBuffer_GetPriority(p) (p)->lpVtbl->GetPriority(p)
480 #define IWineD3DIndexBuffer_PreLoad(p) (p)->lpVtbl->PreLoad(p)
481 #define IWineD3DIndexBuffer_GetType(p) (p)->lpVtbl->GetType(p)
482 /*** IWineD3DIndexBuffer methods ***/
483 #define IWineD3DIndexBuffer_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d)
484 #define IWineD3DIndexBuffer_Unlock(p) (p)->lpVtbl->Unlock(p)
485 #define IWineD3DIndexBuffer_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a)
488 /*****************************************************************************
489 * IWineD3DBaseTexture interface
490 * Note at d3d8 this does NOT extend Resource, but at d3d9 it does
491 * since most functions are common anyway, it makes sense to extend it
493 #define INTERFACE IWineD3DBaseTexture
494 DECLARE_INTERFACE_(IWineD3DBaseTexture,IWineD3DResource)
496 /*** IUnknown methods ***/
497 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
498 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
499 STDMETHOD_(ULONG,Release)(THIS) PURE;
500 /*** IWineD3DResource methods ***/
501 STDMETHOD(GetParent)(THIS_ IUnknown **pParent) PURE;
502 STDMETHOD(GetDevice)(THIS_ IWineD3DDevice ** ppDevice) PURE;
503 STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid, CONST void * pData, DWORD SizeOfData, DWORD Flags) PURE;
504 STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid, void * pData, DWORD * pSizeOfData) PURE;
505 STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
506 STDMETHOD_(DWORD,SetPriority)(THIS_ DWORD PriorityNew) PURE;
507 STDMETHOD_(DWORD,GetPriority)(THIS) PURE;
508 STDMETHOD_(void,PreLoad)(THIS) PURE;
509 STDMETHOD_(D3DRESOURCETYPE,GetType)(THIS) PURE;
510 /*** IWineD3DBaseTexture methods ***/
511 STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE;
512 STDMETHOD_(DWORD, GetLOD)(THIS) PURE;
513 STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE;
514 STDMETHOD(SetAutoGenFilterType)(THIS_ D3DTEXTUREFILTERTYPE FilterType) PURE;
515 STDMETHOD_(D3DTEXTUREFILTERTYPE, GetAutoGenFilterType)(THIS) PURE;
516 STDMETHOD_(void, GenerateMipSubLevels)(THIS) PURE;
517 STDMETHOD_(BOOL, SetDirty)(THIS_ BOOL) PURE;
518 STDMETHOD_(BOOL, GetDirty)(THIS) PURE;
523 #if !defined(__cplusplus) || defined(CINTERFACE)
524 /*** IUnknown methods ***/
525 #define IWineD3DBaseTexture_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
526 #define IWineD3DBaseTexture_AddRef(p) (p)->lpVtbl->AddRef(p)
527 #define IWineD3DBaseTexture_Release(p) (p)->lpVtbl->Release(p)
528 /*** IWineD3DBaseTexture methods: IWineD3DResource ***/
529 #define IWineD3DBaseTexture_GetParent(p,a) (p)->lpVtbl->GetParent(p,a)
530 #define IWineD3DBaseTexture_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
531 #define IWineD3DBaseTexture_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
532 #define IWineD3DBaseTexture_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
533 #define IWineD3DBaseTexture_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
534 #define IWineD3DBaseTexture_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
535 #define IWineD3DBaseTexture_GetPriority(p) (p)->lpVtbl->GetPriority(p)
536 #define IWineD3DBaseTexture_PreLoad(p) (p)->lpVtbl->PreLoad(p)
537 #define IWineD3DBaseTexture_GetType(p) (p)->lpVtbl->GetType(p)
538 /*** IWineD3DBaseTexture methods ***/
539 #define IWineD3DBaseTexture_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a)
540 #define IWineD3DBaseTexture_GetLOD(p) (p)->lpVtbl->GetLOD(p)
541 #define IWineD3DBaseTexture_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p)
542 #define IWineD3DBaseTexture_SetAutoGenFilterType(p,a) (p)->lpVtbl->SetAutoGenFilterType(p,a)
543 #define IWineD3DBaseTexture_GetAutoGenFilterType(p) (p)->lpVtbl->GetAutoGenFilterType(p)
544 #define IWineD3DBaseTexture_GenerateMipSubLevels(p) (p)->lpVtbl->GenerateMipSubLevels(p)
545 #define IWineD3DBaseTexture_SetDirty(p,a) (p)->lpVtbl->SetDirty(p,a)
546 #define IWineD3DBaseTexture_GetDirty(p) (p)->lpVtbl->GetDirty(p)
549 /*****************************************************************************
550 * IWineD3DTexture interface
552 #define INTERFACE IWineD3DTexture
553 DECLARE_INTERFACE_(IWineD3DTexture,IWineD3DBaseTexture)
555 /*** IUnknown methods ***/
556 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
557 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
558 STDMETHOD_(ULONG,Release)(THIS) PURE;
559 /*** IWineD3DResource methods ***/
560 STDMETHOD(GetParent)(THIS_ IUnknown **pParent) PURE;
561 STDMETHOD(GetDevice)(THIS_ IWineD3DDevice ** ppDevice) PURE;
562 STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid, CONST void * pData, DWORD SizeOfData, DWORD Flags) PURE;
563 STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid, void * pData, DWORD * pSizeOfData) PURE;
564 STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
565 STDMETHOD_(DWORD,SetPriority)(THIS_ DWORD PriorityNew) PURE;
566 STDMETHOD_(DWORD,GetPriority)(THIS) PURE;
567 STDMETHOD_(void,PreLoad)(THIS) PURE;
568 STDMETHOD_(D3DRESOURCETYPE,GetType)(THIS) PURE;
569 /*** IWineD3DBaseTexture methods ***/
570 STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE;
571 STDMETHOD_(DWORD, GetLOD)(THIS) PURE;
572 STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE;
573 STDMETHOD(SetAutoGenFilterType)(THIS_ D3DTEXTUREFILTERTYPE FilterType) PURE;
574 STDMETHOD_(D3DTEXTUREFILTERTYPE, GetAutoGenFilterType)(THIS) PURE;
575 STDMETHOD_(void, GenerateMipSubLevels)(THIS) PURE;
576 STDMETHOD_(BOOL, SetDirty)(THIS_ BOOL) PURE;
577 STDMETHOD_(BOOL, GetDirty)(THIS) PURE;
578 /*** IWineD3DTexture methods ***/
579 STDMETHOD(GetLevelDesc)(THIS_ UINT Level, WINED3DSURFACE_DESC* pDesc) PURE;
580 STDMETHOD(GetSurfaceLevel)(THIS_ UINT Level, IWineD3DSurface** ppSurfaceLevel) PURE;
581 STDMETHOD(LockRect)(THIS_ UINT Level, D3DLOCKED_RECT* pLockedRect, CONST RECT* pRect, DWORD Flags) PURE;
582 STDMETHOD(UnlockRect)(THIS_ UINT Level) PURE;
583 STDMETHOD(AddDirtyRect)(THIS_ CONST RECT* pDirtyRect) PURE;
587 #if !defined(__cplusplus) || defined(CINTERFACE)
588 /*** IUnknown methods ***/
589 #define IWineD3DTexture_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
590 #define IWineD3DTexture_AddRef(p) (p)->lpVtbl->AddRef(p)
591 #define IWineD3DTexture_Release(p) (p)->lpVtbl->Release(p)
592 /*** IWineD3DTexture methods: IWineD3DResource ***/
593 #define IWineD3DTexture_GetParent(p,a) (p)->lpVtbl->GetParent(p,a)
594 #define IWineD3DTexture_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
595 #define IWineD3DTexture_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
596 #define IWineD3DTexture_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
597 #define IWineD3DTexture_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
598 #define IWineD3DTexture_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
599 #define IWineD3DTexture_GetPriority(p) (p)->lpVtbl->GetPriority(p)
600 #define IWineD3DTexture_PreLoad(p) (p)->lpVtbl->PreLoad(p)
601 #define IWineD3DTexture_GetType(p) (p)->lpVtbl->GetType(p)
602 /*** IWineD3DTexture methods: IWineD3DBaseTexture ***/
603 #define IWineD3DTexture_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a)
604 #define IWineD3DTexture_GetLOD(p) (p)->lpVtbl->GetLOD(p)
605 #define IWineD3DTexture_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p)
606 #define IWineD3DTexture_SetAutoGenFilterType(p,a) (p)->lpVtbl->SetAutoGenFilterType(p,a)
607 #define IWineD3DTexture_GetAutoGenFilterType(p) (p)->lpVtbl->GetAutoGenFilterType(p)
608 #define IWineD3DTexture_GenerateMipSubLevels(p) (p)->lpVtbl->GenerateMipSubLevels(p)
609 #define IWineD3DTexture_SetDirty(p,a) (p)->lpVtbl->SetDirty(p,a)
610 #define IWineD3DTexture_GetDirty(p) (p)->lpVtbl->GetDirty(p)
611 /*** IWineD3DTexture methods ***/
612 #define IWineD3DTexture_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b)
613 #define IWineD3DTexture_GetSurfaceLevel(p,a,b) (p)->lpVtbl->GetSurfaceLevel(p,a,b)
614 #define IWineD3DTexture_LockRect(p,a,b,c,d) (p)->lpVtbl->LockRect(p,a,b,c,d)
615 #define IWineD3DTexture_UnlockRect(p,a) (p)->lpVtbl->UnlockRect(p,a)
616 #define IWineD3DTexture_AddDirtyRect(p,a) (p)->lpVtbl->AddDirtyRect(p,a)
619 /*****************************************************************************
620 * IWineD3DCubeTexture interface
622 #define INTERFACE IWineD3DCubeTexture
623 DECLARE_INTERFACE_(IWineD3DCubeTexture,IWineD3DBaseTexture)
625 /*** IUnknown methods ***/
626 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
627 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
628 STDMETHOD_(ULONG,Release)(THIS) PURE;
629 /*** IWineD3DResource methods ***/
630 STDMETHOD(GetParent)(THIS_ IUnknown **pParent) PURE;
631 STDMETHOD(GetDevice)(THIS_ IWineD3DDevice ** ppDevice) PURE;
632 STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid, CONST void * pData, DWORD SizeOfData, DWORD Flags) PURE;
633 STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid, void * pData, DWORD * pSizeOfData) PURE;
634 STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
635 STDMETHOD_(DWORD,SetPriority)(THIS_ DWORD PriorityNew) PURE;
636 STDMETHOD_(DWORD,GetPriority)(THIS) PURE;
637 STDMETHOD_(void,PreLoad)(THIS) PURE;
638 STDMETHOD_(D3DRESOURCETYPE,GetType)(THIS) PURE;
639 /*** IWineD3DBaseTexture methods ***/
640 STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE;
641 STDMETHOD_(DWORD, GetLOD)(THIS) PURE;
642 STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE;
643 STDMETHOD(SetAutoGenFilterType)(THIS_ D3DTEXTUREFILTERTYPE FilterType) PURE;
644 STDMETHOD_(D3DTEXTUREFILTERTYPE, GetAutoGenFilterType)(THIS) PURE;
645 STDMETHOD_(void, GenerateMipSubLevels)(THIS) PURE;
646 STDMETHOD_(BOOL, SetDirty)(THIS_ BOOL) PURE;
647 STDMETHOD_(BOOL, GetDirty)(THIS) PURE;
648 /*** IWineD3DCubeTexture methods ***/
649 STDMETHOD(GetLevelDesc)(THIS_ UINT Level,WINED3DSURFACE_DESC* pDesc) PURE;
650 STDMETHOD(GetCubeMapSurface)(THIS_ D3DCUBEMAP_FACES FaceType, UINT Level, IWineD3DSurface** ppCubeMapSurface) PURE;
651 STDMETHOD(LockRect)(THIS_ D3DCUBEMAP_FACES FaceType, UINT Level, D3DLOCKED_RECT* pLockedRect, CONST RECT* pRect, DWORD Flags) PURE;
652 STDMETHOD(UnlockRect)(THIS_ D3DCUBEMAP_FACES FaceType, UINT Level) PURE;
653 STDMETHOD(AddDirtyRect)(THIS_ D3DCUBEMAP_FACES FaceType, CONST RECT* pDirtyRect) PURE;
657 #if !defined(__cplusplus) || defined(CINTERFACE)
658 /*** IUnknown methods ***/
659 #define IWineD3DCubeTexture_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
660 #define IWineD3DCubeTexture_AddRef(p) (p)->lpVtbl->AddRef(p)
661 #define IWineD3DCubeTexture_Release(p) (p)->lpVtbl->Release(p)
662 /*** IWineD3DCubeTexture methods: IWineD3DResource ***/
663 #define IWineD3DCubeTexture_GetParent(p,a) (p)->lpVtbl->GetParent(p,a)
664 #define IWineD3DCubeTexture_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
665 #define IWineD3DCubeTexture_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
666 #define IWineD3DCubeTexture_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
667 #define IWineD3DCubeTexture_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
668 #define IWineD3DCubeTexture_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
669 #define IWineD3DCubeTexture_GetPriority(p) (p)->lpVtbl->GetPriority(p)
670 #define IWineD3DCubeTexture_PreLoad(p) (p)->lpVtbl->PreLoad(p)
671 #define IWineD3DCubeTexture_GetType(p) (p)->lpVtbl->GetType(p)
672 /*** IWineD3DCubeTexture methods: IWineD3DBaseTexture ***/
673 #define IWineD3DCubeTexture_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a)
674 #define IWineD3DCubeTexture_GetLOD(p) (p)->lpVtbl->GetLOD(p)
675 #define IWineD3DCubeTexture_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p)
676 #define IWineD3DCubeTexture_SetAutoGenFilterType(p,a) (p)->lpVtbl->SetAutoGenFilterType(p,a)
677 #define IWineD3DCubeTexture_GetAutoGenFilterType(p) (p)->lpVtbl->GetAutoGenFilterType(p)
678 #define IWineD3DCubeTexture_GenerateMipSubLevels(p) (p)->lpVtbl->GenerateMipSubLevels(p)
679 #define IWineD3DCubeTexture_SetDirty(p,a) (p)->lpVtbl->SetDirty(p,a)
680 #define IWineD3DCubeTexture_GetDirty(p) (p)->lpVtbl->GetDirty(p)
681 /*** IWineD3DCubeTexture methods ***/
682 #define IWineD3DCubeTexture_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b)
683 #define IWineD3DCubeTexture_GetCubeMapSurface(p,a,b,c) (p)->lpVtbl->GetCubeMapSurface(p,a,b,c)
684 #define IWineD3DCubeTexture_LockRect(p,a,b,c,d,e) (p)->lpVtbl->LockRect(p,a,b,c,d,e)
685 #define IWineD3DCubeTexture_UnlockRect(p,a,b) (p)->lpVtbl->UnlockRect(p,a,b)
686 #define IWineD3DCubeTexture_AddDirtyRect(p,a,b) (p)->lpVtbl->AddDirtyRect(p,a,b)
690 /*****************************************************************************
691 * IWineD3DVolumeTexture interface
693 #define INTERFACE IWineD3DVolumeTexture
694 DECLARE_INTERFACE_(IWineD3DVolumeTexture,IWineD3DBaseTexture)
696 /*** IUnknown methods ***/
697 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
698 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
699 STDMETHOD_(ULONG,Release)(THIS) PURE;
700 /*** IWineD3DResource methods ***/
701 STDMETHOD(GetParent)(THIS_ IUnknown **pParent) PURE;
702 STDMETHOD(GetDevice)(THIS_ IWineD3DDevice ** ppDevice) PURE;
703 STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid, CONST void * pData, DWORD SizeOfData, DWORD Flags) PURE;
704 STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid, void * pData, DWORD * pSizeOfData) PURE;
705 STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
706 STDMETHOD_(DWORD,SetPriority)(THIS_ DWORD PriorityNew) PURE;
707 STDMETHOD_(DWORD,GetPriority)(THIS) PURE;
708 STDMETHOD_(void,PreLoad)(THIS) PURE;
709 STDMETHOD_(D3DRESOURCETYPE,GetType)(THIS) PURE;
710 /*** IWineD3DBaseTexture methods ***/
711 STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE;
712 STDMETHOD_(DWORD, GetLOD)(THIS) PURE;
713 STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE;
714 STDMETHOD(SetAutoGenFilterType)(THIS_ D3DTEXTUREFILTERTYPE FilterType) PURE;
715 STDMETHOD_(D3DTEXTUREFILTERTYPE, GetAutoGenFilterType)(THIS) PURE;
716 STDMETHOD_(void, GenerateMipSubLevels)(THIS) PURE;
717 STDMETHOD_(BOOL, SetDirty)(THIS_ BOOL) PURE;
718 STDMETHOD_(BOOL, GetDirty)(THIS) PURE;
719 /*** IWineD3DVolumeTexture methods ***/
720 STDMETHOD(GetLevelDesc)(THIS_ UINT Level, WINED3DVOLUME_DESC *pDesc) PURE;
721 STDMETHOD(GetVolumeLevel)(THIS_ UINT Level, IWineD3DVolume** ppVolumeLevel) PURE;
722 STDMETHOD(LockBox)(THIS_ UINT Level, D3DLOCKED_BOX* pLockedVolume, CONST D3DBOX* pBox, DWORD Flags) PURE;
723 STDMETHOD(UnlockBox)(THIS_ UINT Level) PURE;
724 STDMETHOD(AddDirtyBox)(THIS_ CONST D3DBOX* pDirtyBox) PURE;
728 #if !defined(__cplusplus) || defined(CINTERFACE)
729 /*** IUnknown methods ***/
730 #define IWineD3DVolumeTexture_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
731 #define IWineD3DVolumeTexture_AddRef(p) (p)->lpVtbl->AddRef(p)
732 #define IWineD3DVolumeTexture_Release(p) (p)->lpVtbl->Release(p)
733 /*** IWineD3DVolumeTexture methods: IWineD3DResource ***/
734 #define IWineD3DVolumeTexture_GetParent(p,a) (p)->lpVtbl->GetParent(p,a)
735 #define IWineD3DVolumeTexture_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
736 #define IWineD3DVolumeTexture_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
737 #define IWineD3DVolumeTexture_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
738 #define IWineD3DVolumeTexture_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
739 #define IWineD3DVolumeTexture_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
740 #define IWineD3DVolumeTexture_GetPriority(p) (p)->lpVtbl->GetPriority(p)
741 #define IWineD3DVolumeTexture_PreLoad(p) (p)->lpVtbl->PreLoad(p)
742 #define IWineD3DVolumeTexture_GetType(p) (p)->lpVtbl->GetType(p)
743 /*** IWineD3DVolumeTexture methods: IWineD3DBaseTexture ***/
744 #define IWineD3DVolumeTexture_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a)
745 #define IWineD3DVolumeTexture_GetLOD(p) (p)->lpVtbl->GetLOD(p)
746 #define IWineD3DVolumeTexture_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p)
747 #define IWineD3DVolumeTexture_SetAutoGenFilterType(p,a) (p)->lpVtbl->SetAutoGenFilterType(p,a)
748 #define IWineD3DVolumeTexture_GetAutoGenFilterType(p) (p)->lpVtbl->GetAutoGenFilterType(p)
749 #define IWineD3DVolumeTexture_GenerateMipSubLevels(p) (p)->lpVtbl->GenerateMipSubLevels(p)
750 #define IWineD3DVolumeTexture_SetDirty(p,a) (p)->lpVtbl->SetDirty(p,a)
751 #define IWineD3DVolumeTexture_GetDirty(p) (p)->lpVtbl->GetDirty(p)
753 /*** IWineD3DVolumeTexture methods ***/
754 #define IWineD3DVolumeTexture_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b)
755 #define IWineD3DVolumeTexture_GetVolumeLevel(p,a,b) (p)->lpVtbl->GetVolumeLevel(p,a,b)
756 #define IWineD3DVolumeTexture_LockBox(p,a,b,c,d) (p)->lpVtbl->LockBox(p,a,b,c,d)
757 #define IWineD3DVolumeTexture_UnlockBox(p,a) (p)->lpVtbl->UnlockBox(p,a)
758 #define IWineD3DVolumeTexture_AddDirtyBox(p,a) (p)->lpVtbl->AddDirtyBox(p,a)
761 /*****************************************************************************
762 * IWineD3DSurface interface
764 #define INTERFACE IWineD3DSurface
765 DECLARE_INTERFACE_(IWineD3DSurface,IWineD3DResource)
767 /*** IUnknown methods ***/
768 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
769 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
770 STDMETHOD_(ULONG,Release)(THIS) PURE;
771 /*** IWineD3DResource methods ***/
772 STDMETHOD(GetParent)(THIS_ IUnknown **pParent) PURE;
773 STDMETHOD(GetDevice)(THIS_ IWineD3DDevice ** ppDevice) PURE;
774 STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid, CONST void * pData, DWORD SizeOfData, DWORD Flags) PURE;
775 STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid, void * pData, DWORD * pSizeOfData) PURE;
776 STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
777 STDMETHOD_(DWORD,SetPriority)(THIS_ DWORD PriorityNew) PURE;
778 STDMETHOD_(DWORD,GetPriority)(THIS) PURE;
779 STDMETHOD_(void,PreLoad)(THIS) PURE;
780 STDMETHOD_(D3DRESOURCETYPE,GetType)(THIS) PURE;
781 /*** IWineD3DSurface methods ***/
782 STDMETHOD(GetContainer)(THIS_ REFIID riid, void ** ppContainer) PURE;
783 STDMETHOD(GetDesc)(THIS_ WINED3DSURFACE_DESC * pDesc) PURE;
784 STDMETHOD(LockRect)(THIS_ D3DLOCKED_RECT * pLockedRect, CONST RECT * pRect,DWORD Flags) PURE;
785 STDMETHOD(UnlockRect)(THIS) PURE;
786 STDMETHOD(GetDC)(THIS_ HDC *pHdc) PURE;
787 STDMETHOD(ReleaseDC)(THIS_ HDC hdc) PURE;
788 /* Internally used methods */
789 STDMETHOD(CleanDirtyRect)(THIS) PURE;
790 STDMETHOD(AddDirtyRect)(THIS_ CONST RECT* pRect) PURE;
791 STDMETHOD(LoadTexture)(THIS_ UINT gl_target, UINT gl_level) PURE;
792 STDMETHOD(SaveSnapshot)(THIS_ const char *filename) PURE;
796 #if !defined(__cplusplus) || defined(CINTERFACE)
797 /*** IUnknown methods ***/
798 #define IWineD3DSurface_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
799 #define IWineD3DSurface_AddRef(p) (p)->lpVtbl->AddRef(p)
800 #define IWineD3DSurface_Release(p) (p)->lpVtbl->Release(p)
801 /*** IWineD3DResource methods ***/
802 /*** IWineD3DResource methods ***/
803 #define IWineD3DSurface_GetParent(p,a) (p)->lpVtbl->GetParent(p,a)
804 #define IWineD3DSurface_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
805 #define IWineD3DSurface_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
806 #define IWineD3DSurface_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
807 #define IWineD3DSurface_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
808 #define IWineD3DSurface_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
809 #define IWineD3DSurface_GetPriority(p) (p)->lpVtbl->GetPriority(p)
810 #define IWineD3DSurface_PreLoad(p) (p)->lpVtbl->PreLoad(p)
811 #define IWineD3DSurface_GetType(p) (p)->lpVtbl->GetType(p)
812 /*** IWineD3DSurface methods ***/
813 #define IWineD3DSurface_GetContainer(p,a,b) (p)->lpVtbl->GetContainer(p,a,b)
814 #define IWineD3DSurface_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a)
815 #define IWineD3DSurface_LockRect(p,a,b,c) (p)->lpVtbl->LockRect(p,a,b,c)
816 #define IWineD3DSurface_UnlockRect(p) (p)->lpVtbl->UnlockRect(p)
817 #define IWineD3DSurface_GetDC(p,a) (p)->lpVtbl->GetDC(p,a)
818 #define IWineD3DSurface_ReleaseDC(p,a) (p)->lpVtbl->ReleaseDC(p,a)
819 /*** IWineD3DSurface (Internal, no d3d mapping) methods ***/
820 #define IWineD3DSurface_CleanDirtyRect(p) (p)->lpVtbl->CleanDirtyRect(p)
821 #define IWineD3DSurface_AddDirtyRect(p,a) (p)->lpVtbl->AddDirtyRect(p,a)
822 #define IWineD3DSurface_LoadTexture(p,a,b) (p)->lpVtbl->LoadTexture(p,a,b)
823 #define IWineD3DSurface_SaveSnapshot(p,a) (p)->lpVtbl->SaveSnapshot(p,a)
826 /*****************************************************************************
827 * IWineD3DVolume interface
829 #define INTERFACE IWineD3DVolume
830 DECLARE_INTERFACE_(IWineD3DVolume,IUnknown)
832 /*** IUnknown methods ***/
833 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
834 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
835 STDMETHOD_(ULONG,Release)(THIS) PURE;
836 /*** IWineD3DVolume methods ***/
837 STDMETHOD(GetParent)(THIS_ IUnknown **pParent) PURE;
838 STDMETHOD(GetDevice)(THIS_ IWineD3DDevice ** ppDevice) PURE;
839 STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid, CONST void * pData, DWORD SizeOfData, DWORD Flags) PURE;
840 STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid, void * pData, DWORD * pSizeOfData) PURE;
841 STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
842 STDMETHOD(GetContainer)(THIS_ REFIID riid, void ** ppContainer) PURE;
843 STDMETHOD(GetDesc)(THIS_ WINED3DVOLUME_DESC * pDesc) PURE;
844 STDMETHOD(LockBox)(THIS_ D3DLOCKED_BOX* pLockedVolume, CONST D3DBOX* pBox, DWORD Flags) PURE;
845 STDMETHOD(UnlockBox)(THIS) PURE;
846 STDMETHOD(AddDirtyBox)(THIS_ CONST D3DBOX* pDirtyBox) PURE;
847 STDMETHOD(CleanDirtyBox)(THIS) PURE;
851 #if !defined(__cplusplus) || defined(CINTERFACE)
852 /*** IUnknown methods ***/
853 #define IWineD3DVolume_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
854 #define IWineD3DVolume_AddRef(p) (p)->lpVtbl->AddRef(p)
855 #define IWineD3DVolume_Release(p) (p)->lpVtbl->Release(p)
856 /*** IWineD3DVolume methods ***/
857 #define IWineD3DVolume_GetParent(p,a) (p)->lpVtbl->GetParent(p,a)
858 #define IWineD3DVolume_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
859 #define IWineD3DVolume_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
860 #define IWineD3DVolume_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
861 #define IWineD3DVolume_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
862 #define IWineD3DVolume_GetContainer(p,a,b) (p)->lpVtbl->GetContainer(p,a,b)
863 #define IWineD3DVolume_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a)
864 #define IWineD3DVolume_LockBox(p,a,b,c) (p)->lpVtbl->LockBox(p,a,b,c)
865 #define IWineD3DVolume_UnlockBox(p) (p)->lpVtbl->UnlockBox(p)
866 #define IWineD3DVolume_AddDirtyBox(p,a) (p)->lpVtbl->AddDirtyBox(p,a)
867 #define IWineD3DVolume_CleanDirtyBox(p) (p)->lpVtbl->CleanDirtyBox(p)
870 /*****************************************************************************
871 * IWineD3DVertexDeclaration interface
873 #define INTERFACE IWineD3DVertexDeclaration
874 DECLARE_INTERFACE_(IWineD3DVertexDeclaration,IUnknown)
876 /*** IUnknown methods ***/
877 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
878 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
879 STDMETHOD_(ULONG,Release)(THIS) PURE;
880 /*** IWineD3DVertexDeclaration methods ***/
881 STDMETHOD(GetDevice)(THIS_ IWineD3DDevice ** ppDevice) PURE;
882 STDMETHOD(GetDeclaration)(THIS_ UINT iDeclVersion, VOID*, DWORD* pSize) PURE;
886 #if !defined(__cplusplus) || defined(CINTERFACE)
887 /*** IUnknown methods ***/
888 #define IWineD3DVertexDeclaration_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
889 #define IWineD3DVertexDeclaration_AddRef(p) (p)->lpVtbl->AddRef(p)
890 #define IWineD3DVertexDeclaration_Release(p) (p)->lpVtbl->Release(p)
891 /*** IWineD3DVertexDeclaration methods ***/
892 #define IWineD3DVertexDeclaration_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
893 #define IWineD3DVertexDeclaration_GetDeclaration(p,a,b,c) (p)->lpVtbl->GetDeclaration(p,a,b,c)
896 /*****************************************************************************
897 * IWineD3DStateBlock interface
899 #define INTERFACE IWineD3DStateBlock
900 DECLARE_INTERFACE_(IWineD3DStateBlock,IUnknown)
902 /*** IUnknown methods ***/
903 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
904 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
905 STDMETHOD_(ULONG,Release)(THIS) PURE;
906 /*** IWineD3DStateBlock methods ***/
907 STDMETHOD(GetParent)(THIS_ IUnknown **pParent) PURE;
908 STDMETHOD(InitStartupStateBlock)(THIS) PURE;
912 #if !defined(__cplusplus) || defined(CINTERFACE)
913 /*** IUnknown methods ***/
914 #define IWineD3DStateBlock_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
915 #define IWineD3DStateBlock_AddRef(p) (p)->lpVtbl->AddRef(p)
916 #define IWineD3DStateBlock_Release(p) (p)->lpVtbl->Release(p)
917 /*** IWineD3DStateBlock methods ***/
918 #define IWineD3DStateBlock_GetParent(p,a) (p)->lpVtbl->GetParent(p,a)
919 #define IWineD3DStateBlock_InitStartupStateBlock(p) (p)->lpVtbl->InitStartupStateBlock(p)
923 /*****************************************************************************
924 * IWineD3DVertexShader interface
926 #define INTERFACE IWineD3DVertexShader
927 DECLARE_INTERFACE_(IWineD3DVertexShader,IUnknown)
929 /*** IUnknown methods ***/
930 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
931 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
932 STDMETHOD_(ULONG,Release)(THIS) PURE;
933 /*** IWineD3DVertexShader methods ***/
934 STDMETHOD(GetFunction)(THIS_ VOID* pData, UINT* pSizeOfData) PURE;
935 STDMETHOD(SetConstantB)(THIS_ UINT StartRegister, CONST BOOL* pConstantData, UINT BoolCount) PURE;
936 STDMETHOD(SetConstantI)(THIS_ UINT StartRegister, CONST INT* pConstantData, UINT Vector4iCount) PURE;
937 STDMETHOD(SetConstantF)(THIS_ UINT StartRegister, CONST FLOAT* pConstantData, UINT Vector4fCount) PURE;
938 STDMETHOD(GetConstantB)(THIS_ UINT StartRegister, BOOL* pConstantData, UINT BoolCount) PURE;
939 STDMETHOD(GetConstantI)(THIS_ UINT StartRegister, INT* pConstantData, UINT Vector4iCount) PURE;
940 STDMETHOD(GetConstantF)(THIS_ UINT StartRegister, FLOAT* pConstantData, UINT Vector4fCount) PURE;
941 /* Internal Interfaces */
942 STDMETHOD_(DWORD, GetVersion)(THIS) PURE;
946 #if !defined(__cplusplus) || defined(CINTERFACE)
947 /*** IUnknown methods ***/
948 #define IWineD3DVertexShader_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
949 #define IWineD3DVertexShader_AddRef(p) (p)->lpVtbl->AddRef(p)
950 #define IWineD3DVertexShader_Release(p) (p)->lpVtbl->Release(p)
951 /*** IWineD3DVertexShader methods ***/
952 #define IWineD3DVertexShader_GetFunction(p,a,b) (p)->lpVtbl->GetFunction(p,a,b)
953 #define IWineD3DVertexShader_SetConstantB(p,a,b,c) (p)->lpVtbl->SetConstantB(p,a,b,c)
954 #define IWineD3DVertexShader_SetConstantI(p,a,b,c) (p)->lpVtbl->SetConstantI(p,a,b,c)
955 #define IWineD3DVertexShader_SetConstantF(p,a,b,c) (p)->lpVtbl->SetConstantF(p,a,b,c)
956 #define IWineD3DVertexShader_GetConstantB(p,a,b,c) (p)->lpVtbl->GetConstantB(p,a,b,c)
957 #define IWineD3DVertexShader_GetConstantI(p,a,b,c) (p)->lpVtbl->GetConstantI(p,a,b,c)
958 #define IWineD3DVertexShader_GetConstantF(p,a,b,c) (p)->lpVtbl->GetConstantF(p,a,b,c)
959 #define IWineD3DVertexShader_GetVersion(p) (p)->lpVtbl->GetVersion(p)
962 /*****************************************************************************
963 * IWineD3DPixelShader interface
965 #define INTERFACE IWineD3DPixelShader
966 DECLARE_INTERFACE_(IWineD3DPixelShader,IUnknown)
968 /*** IUnknown methods ***/
969 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
970 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
971 STDMETHOD_(ULONG,Release)(THIS) PURE;
972 /*** IWineD3DPixelShader methods ***/
973 STDMETHOD(GetFunction)(THIS_ VOID* pData, UINT* pSizeOfData) PURE;
974 STDMETHOD(SetConstantF)(THIS_ UINT StartRegister, CONST FLOAT* pConstantData, UINT Vector4fCount) PURE;
975 STDMETHOD(GetConstantF)(THIS_ UINT StartRegister, FLOAT* pConstantData, UINT Vector4fCount) PURE;
976 /* Internal Interfaces */
977 STDMETHOD_(DWORD, GetVersion)(THIS) PURE;
981 #if !defined(__cplusplus) || defined(CINTERFACE)
982 /*** IUnknown methods ***/
983 #define IWineD3DPixelShader_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
984 #define IWineD3DPixelShader_AddRef(p) (p)->lpVtbl->AddRef(p)
985 #define IWineD3DPixelShader_Release(p) (p)->lpVtbl->Release(p)
986 /*** IWineD3DPixelShader methods ***/
987 #define IWineD3DPixelShader_GetFunction(p,a,b) (p)->lpVtbl->GetFunction(p,a,b)
988 #define IWineD3DPixelShader_SetConstantF(p,a,b,c) (p)->lpVtbl->SetConstantF(p,a,b,c)
989 #define IWineD3DPixelShader_GetConstantF(p,a,b,c) (p)->lpVtbl->GetConstantF(p,a,b,c)
990 #define IWineD3DPixelShader_GetVersion(p) (p)->lpVtbl->GetVersion(p)
993 #if 0 /* FIXME: During porting in from d3d8 - the following will be used */
994 extern HRESULT WINAPI IDirect3DVertexShaderImpl_ParseProgram(IDirect3DVertexShaderImpl* This, CONST DWORD* pFunction);
995 /* internal Interfaces */
996 extern HRESULT WINAPI IDirect3DVertexShaderImpl_ExecuteSW(IDirect3DVertexShaderImpl* This, VSHADERINPUTDATA* input, VSHADEROUTPUTDATA* output);
997 #endif /* Temporary #if 0 */