d3dx9: Fix the LPLPD3DXFILE typedef.
[wine] / include / d3dhal.h
1 /*
2  * Direct3D driver interface
3  * (DirectX 7 version)
4  *
5  * Copyright (C) 2001 Ove Kaaven
6  *
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.
11  *
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.
16  *
17  * You should have received a copy of the GNU Lesser General Public
18  * License along with this library; if not, write to the Free Software
19  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
20  */
21
22 #ifndef __WINE_D3DHAL_H
23 #define __WINE_D3DHAL_H
24
25 #ifdef __cplusplus
26 extern "C" {
27 #endif
28
29 #include <d3d.h>
30
31 /*****************************************************************************
32  * device info structures
33  */
34 typedef struct _D3DDeviceDesc_V1 {
35   DWORD                 dwSize;
36   DWORD                 dwFlags;
37   D3DCOLORMODEL         dcmColorModel;
38   DWORD                 dwDevCaps;
39   D3DTRANSFORMCAPS      dtcTransformCaps;
40   BOOL                  bClipping;
41   D3DLIGHTINGCAPS       dlcLightingCaps;
42   D3DPRIMCAPS           dpcLineCaps;
43   D3DPRIMCAPS           dpcTriCaps;
44   DWORD                 dwDeviceRenderBitDepth;
45   DWORD                 dwDeviceZBufferBitDepth;
46   DWORD                 dwMaxBufferSize;
47   DWORD                 dwMaxVertexCount;
48 } D3DDEVICEDESC_V1,*LPD3DDEVICEDESC_V1;
49
50 typedef struct _D3DHAL_GLOBALDRIVERDATA {
51   DWORD                 dwSize;
52   D3DDEVICEDESC_V1      hwCaps;
53   DWORD                 dwNumVertices;
54   DWORD                 dwNumClipVertices;
55   DWORD                 dwNumTextureFormats;
56   LPDDSURFACEDESC       lpTextureFormats;
57 } D3DHAL_GLOBALDRIVERDATA,*LPD3DHAL_GLOBALDRIVERDATA;
58
59 typedef struct _D3DHAL_D3DEXTENDEDCAPS {
60   DWORD                 dwSize;
61   /* DirectX 5 */
62   DWORD                 dwMinTextureWidth, dwMaxTextureWidth;
63   DWORD                 dwMinTextureHeight, dwMaxTextureHeight;
64   DWORD                 dwMinStippleWidth, dwMaxStippleWidth;
65   DWORD                 dwMinStippleHeight, dwMaxStippleHeight;
66   /* DirectX 6 */
67   DWORD                 dwMaxTextureRepeat;
68   DWORD                 dwMaxTextureAspectRatio;
69   DWORD                 dwMaxAnisotropy;
70   D3DVALUE              dvGuardBandLeft;
71   D3DVALUE              dvGuardBandTop;
72   D3DVALUE              dvGuardBandRight;
73   D3DVALUE              dvGuardBandBottom;
74   D3DVALUE              dvExtentsAdjust;
75   DWORD                 dwStencilCaps;
76   DWORD                 dwFVFCaps;
77   DWORD                 dwTextureOpCaps;
78   WORD                  wMaxTextureBlendStages;
79   WORD                  wMaxSimultaneousTextures;
80   /* DirectX 7 */
81   DWORD                 dwMaxActiveLights;
82   D3DVALUE              dvMaxVertexW;
83   WORD                  wMaxUserClipPlanes;
84   WORD                  wMaxVertexBlendMatrices;
85   DWORD                 dwVertexProcessingCaps;
86   DWORD                 dwReserved1;
87   DWORD                 dwReserved2;
88   DWORD                 dwReserved3;
89   DWORD                 dwReserved4;
90 } D3DHAL_D3DEXTENDEDCAPS,*LPD3DHAL_D3DEXTENDEDCAPS;
91
92 /*****************************************************************************
93  * d3d->driver callbacks
94  */
95 typedef struct _D3DHAL_CONTEXTCREATEDATA        *LPD3DHAL_CONTEXTCREATEDATA;
96 typedef struct _D3DHAL_CONTEXTDESTROYDATA       *LPD3DHAL_CONTEXTDESTROYDATA;
97 typedef struct _D3DHAL_CONTEXTDESTROYALLDATA    *LPD3DHAL_CONTEXTDESTROYALLDATA;
98 typedef struct _D3DHAL_SCENECAPTUREDATA         *LPD3DHAL_SCENECAPTUREDATA;
99 typedef struct _D3DHAL_RENDERSTATEDATA          *LPD3DHAL_RENDERSTATEDATA;
100 typedef struct _D3DHAL_RENDERPRIMITIVEDATA      *LPD3DHAL_RENDERPRIMITIVEDATA;
101 typedef struct _D3DHAL_TEXTURECREATEDATA        *LPD3DHAL_TEXTURECREATEDATA;
102 typedef struct _D3DHAL_TEXTUREDESTROYDATA       *LPD3DHAL_TEXTUREDESTROYDATA;
103 typedef struct _D3DHAL_TEXTURESWAPDATA          *LPD3DHAL_TEXTURESWAPDATA;
104 typedef struct _D3DHAL_TEXTUREGETSURFDATA       *LPD3DHAL_TEXTUREGETSURFDATA;
105 typedef struct _D3DHAL_GETSTATEDATA             *LPD3DHAL_GETSTATEDATA;
106
107 typedef DWORD (PASCAL *LPD3DHAL_CONTEXTCREATECB)    (LPD3DHAL_CONTEXTCREATEDATA);
108 typedef DWORD (PASCAL *LPD3DHAL_CONTEXTDESTROYCB)   (LPD3DHAL_CONTEXTDESTROYDATA);
109 typedef DWORD (PASCAL *LPD3DHAL_CONTEXTDESTROYALLCB)(LPD3DHAL_CONTEXTDESTROYALLDATA);
110 typedef DWORD (PASCAL *LPD3DHAL_SCENECAPTURECB)     (LPD3DHAL_SCENECAPTUREDATA);
111 typedef DWORD (PASCAL *LPD3DHAL_RENDERSTATECB)      (LPD3DHAL_RENDERSTATEDATA);
112 typedef DWORD (PASCAL *LPD3DHAL_RENDERPRIMITIVECB)  (LPD3DHAL_RENDERPRIMITIVEDATA);
113 typedef DWORD (PASCAL *LPD3DHAL_TEXTURECREATECB)    (LPD3DHAL_TEXTURECREATEDATA);
114 typedef DWORD (PASCAL *LPD3DHAL_TEXTUREDESTROYCB)   (LPD3DHAL_TEXTUREDESTROYDATA);
115 typedef DWORD (PASCAL *LPD3DHAL_TEXTURESWAPCB)      (LPD3DHAL_TEXTURESWAPDATA);
116 typedef DWORD (PASCAL *LPD3DHAL_TEXTUREGETSURFCB)   (LPD3DHAL_TEXTUREGETSURFDATA);
117 typedef DWORD (PASCAL *LPD3DHAL_GETSTATECB)         (LPD3DHAL_GETSTATEDATA);
118
119 typedef struct _D3DHAL_CALLBACKS {
120   DWORD                         dwSize;
121   LPD3DHAL_CONTEXTCREATECB      ContextCreate;
122   LPD3DHAL_CONTEXTDESTROYCB     ContextDestroy;
123   LPD3DHAL_CONTEXTDESTROYALLCB  ContextDestroyAll;
124   LPD3DHAL_SCENECAPTURECB       SceneCapture;
125   LPVOID                        lpReserved10;
126   LPVOID                        lpReserved11;
127   LPD3DHAL_RENDERSTATECB        RenderState;
128   LPD3DHAL_RENDERPRIMITIVECB    RenderPrimitive;
129   DWORD                         dwReserved;
130   LPD3DHAL_TEXTURECREATECB      TextureCreate;
131   LPD3DHAL_TEXTUREDESTROYCB     TextureDestroy;
132   LPD3DHAL_TEXTURESWAPCB        TextureSwap;
133   LPD3DHAL_TEXTUREGETSURFCB     TextureGetSurf;
134   /* now why did MS create CALLBACKS2 and CALLBACKS3 structures if
135    * all these reserved fields were available? we may never know */
136   LPVOID                        lpReserved12;
137   LPVOID                        lpReserved13;
138   LPVOID                        lpReserved14;
139   LPVOID                        lpReserved15;
140   LPVOID                        lpReserved16;
141   LPVOID                        lpReserved17;
142   LPVOID                        lpReserved18;
143   LPVOID                        lpReserved19;
144   LPVOID                        lpReserved20;
145   LPVOID                        lpReserved21;
146   LPD3DHAL_GETSTATECB           GetState;
147   DWORD                         dwReserved0;
148   DWORD                         dwReserved1;
149   DWORD                         dwReserved2;
150   DWORD                         dwReserved3;
151   DWORD                         dwReserved4;
152   DWORD                         dwReserved5;
153   DWORD                         dwReserved6;
154   DWORD                         dwReserved7;
155   DWORD                         dwReserved8;
156   DWORD                         dwReserved9;
157 } D3DHAL_CALLBACKS,*LPD3DHAL_CALLBACKS;
158
159 typedef struct _D3DHAL_SETRENDERTARGETDATA              *LPD3DHAL_SETRENDERTARGETDATA;
160 typedef struct _D3DHAL_CLEARDATA                        *LPD3DHAL_CLEARDATA;
161 typedef struct _D3DHAL_DRAWONEPRIMITIVEDATA             *LPD3DHAL_DRAWONEPRIMITIVEDATA;
162 typedef struct _D3DHAL_DRAWONEINDEXEDPRIMITIVEDATA      *LPD3DHAL_DRAWONEINDEXEDPRIMITIVEDATA;
163 typedef struct _D3DHAL_DRAWPRIMITIVESDATA               *LPD3DHAL_DRAWPRIMITIVESDATA;
164
165 typedef DWORD (PASCAL *LPD3DHAL_SETRENDERTARGETCB)        (LPD3DHAL_SETRENDERTARGETDATA);
166 typedef DWORD (PASCAL *LPD3DHAL_CLEARCB)                  (LPD3DHAL_CLEARDATA);
167 typedef DWORD (PASCAL *LPD3DHAL_DRAWONEPRIMITIVECB)       (LPD3DHAL_DRAWONEPRIMITIVEDATA);
168 typedef DWORD (PASCAL *LPD3DHAL_DRAWONEINDEXEDPRIMITIVECB)(LPD3DHAL_DRAWONEINDEXEDPRIMITIVEDATA);
169 typedef DWORD (PASCAL *LPD3DHAL_DRAWPRIMITIVESCB)         (LPD3DHAL_DRAWPRIMITIVESDATA);
170
171 typedef struct _D3DHAL_CALLBACKS2 {
172   DWORD                                 dwSize;
173   DWORD                                 dwFlags;
174   LPD3DHAL_SETRENDERTARGETCB            SetRenderTarget;
175   LPD3DHAL_CLEARCB                      Clear;
176   LPD3DHAL_DRAWONEPRIMITIVECB           DrawOnePrimitive;
177   LPD3DHAL_DRAWONEINDEXEDPRIMITIVECB    DrawOneIndexedPrimitive;
178   LPD3DHAL_DRAWPRIMITIVESCB             DrawPrimitives;
179 } D3DHAL_CALLBACKS2,*LPD3DHAL_CALLBACKS2;
180
181 typedef struct _D3DHAL_CLEAR2DATA                       *LPD3DHAL_CLEAR2DATA;
182 typedef struct _D3DHAL_VALIDATETEXTURESTAGESTATEDATA    *LPD3DHAL_VALIDATETEXTURESTAGESTATEDATA;
183 typedef struct _D3DHAL_DRAWPRIMITIVES2DATA              *LPD3DHAL_DRAWPRIMITIVES2DATA;
184
185 typedef DWORD (PASCAL *LPD3DHAL_CLEAR2CB)                 (LPD3DHAL_CLEAR2DATA);
186 typedef DWORD (PASCAL *LPD3DHAL_VALIDATETEXTURESTAGESTATECB)(LPD3DHAL_VALIDATETEXTURESTAGESTATEDATA);
187 typedef DWORD (PASCAL *LPD3DHAL_DRAWPRIMITIVES2CB)        (LPD3DHAL_DRAWPRIMITIVES2DATA);
188
189 typedef struct _D3DHAL_CALLBACKS3 {
190   DWORD                                 dwSize;
191   DWORD                                 dwFlags;
192   LPD3DHAL_CLEAR2CB                     Clear2;
193   LPVOID                                lpvReserved;
194   LPD3DHAL_VALIDATETEXTURESTAGESTATECB  ValidateTextureStageState;
195   LPD3DHAL_DRAWPRIMITIVES2CB            DrawPrimitives2;
196 } D3DHAL_CALLBACKS3,*LPD3DHAL_CALLBACKS3;
197
198 /*****************************************************************************
199  * parameter structures
200  */
201 typedef struct _D3DHAL_CONTEXTCREATEDATA {
202   union {
203     LPDDRAWI_DIRECTDRAW_GBL     lpDDGbl; /* pre-DirectX 7 */
204     LPDDRAWI_DIRECTDRAW_LCL     lpDDLcl; /* DirectX 7 */
205   } DUMMYUNIONNAME1;
206   union {
207     LPDIRECTDRAWSURFACE         lpDDS;
208     LPDDRAWI_DDRAWSURFACE_LCL   lpDDSLcl; /* DirectX 7 */
209   } DUMMYUNIONNAME2;
210   union {
211     LPDIRECTDRAWSURFACE         lpDDSZ;
212     LPDDRAWI_DDRAWSURFACE_LCL   lpDDSZLcl; /* DirectX 7 */
213   } DUMMYUNIONNAME3;
214   union {
215     DWORD                       dwPID;
216     ULONG_PTR                   dwrstates;
217   } DUMMYUNIONNAME4;
218   ULONG_PTR                     dwhContext;
219   HRESULT                       ddrval;
220 } D3DHAL_CONTEXTCREATEDATA;
221
222 typedef struct _D3DHAL_CONTEXTDESTROYDATA {
223   ULONG_PTR                     dwhContext;
224   HRESULT                       ddrval;
225 } D3DHAL_CONTEXTDESTROYDATA;
226
227 typedef struct _D3DHAL_CONTEXTDESTROYALLDATA {
228   DWORD                         dwPID;
229   HRESULT                       ddrval;
230 } D3DHAL_CONTEXTDESTROYALLDATA;
231
232 typedef struct _D3DHAL_SCENECAPTUREDATA {
233   ULONG_PTR                     dwhContext;
234   DWORD                         dwFlag;
235   HRESULT                       ddrval;
236 } D3DHAL_SCENECAPTUREDATA;
237
238 #define D3DHAL_SCENE_CAPTURE_START      0x00000000
239 #define D3DHAL_SCENE_CAPTURE_END        0x00000001
240
241 typedef struct _D3DHAL_SETRENDERTARGETDATA {
242   ULONG_PTR                     dwhContext;
243   union {
244     LPDIRECTDRAWSURFACE         lpDDS;
245     LPDDRAWI_DDRAWSURFACE_LCL   lpDDSLcl;
246   } DUMMYUNIONNAME1;
247   union {
248     LPDIRECTDRAWSURFACE         lpDDSZ;
249     LPDDRAWI_DDRAWSURFACE_LCL   lpDDSZLcl;
250   } DUMMYUNIONNAME2;
251   HRESULT                       ddrval;
252 } D3DHAL_SETRENDERTARGETDATA;
253
254 typedef struct _D3DHAL_DRAWPRIMITIVES2DATA {
255   ULONG_PTR                     dwhContext;
256   DWORD                         dwFlags;
257   DWORD                         dwVertexType;
258   LPDDRAWI_DDRAWSURFACE_LCL     lpDDCommands;
259   DWORD                         dwCommandOffset;
260   DWORD                         dwCommandLength;
261   union {
262     LPDDRAWI_DDRAWSURFACE_LCL   lpDDVertex;
263     LPVOID                      lpVertices;
264   } DUMMYUNIONNAME1;
265   DWORD                         dwVertexOffset;
266   DWORD                         dwVertexLength;
267   DWORD                         dwReqVertexBufSize;
268   DWORD                         dwReqCommandBufSize;
269   LPDWORD                       lpdwRStates;
270   union {
271     DWORD                       dwVertexSize;
272     HRESULT                     ddrval;
273   } DUMMYUNIONNAME2;
274   DWORD                         dwErrorOffset;
275 } D3DHAL_DRAWPRIMITIVES2DATA;
276
277 #define D3DHALDP2_USERMEMVERTICES       0x00000001
278 #define D3DHALDP2_EXECUTEBUFFER         0x00000002
279 #define D3DHALDP2_SWAPVERTEXBUFFER      0x00000004
280 #define D3DHALDP2_SWAPCOMMANDBUFFER     0x00000008
281 #define D3DHALDP2_REQVERTEXBUFSIZE      0x00000010
282 #define D3DHALDP2_REQCOMMANDBUFSIZE     0x00000020
283 #define D3DHALDP2_VIDMEMVERTEXBUF       0x00000040
284 #define D3DHALDP2_VIDMEMCOMMANDBUF      0x00000080
285
286 /*****************************************************************************
287  * DrawPrimitives2 command structures
288  */
289 typedef struct _D3DHAL_DP2COMMAND {
290   BYTE bCommand;
291   BYTE bReserved;
292   union {
293     WORD wPrimitiveCount;
294     WORD wStateCount;
295   } DUMMYUNIONNAME;
296 } D3DHAL_DP2COMMAND,*LPD3DHAL_DP2COMMAND;
297
298 typedef enum _D3DHAL_DP2OPERATION {
299   D3DDP2OP_POINTS               = 1,
300   D3DDP2OP_INDEXEDLINELIST      = 2,
301   D3DDP2OP_INDEXEDTRIANGLELIST  = 3,
302   D3DDP2OP_RENDERSTATE          = 8,
303   D3DDP2OP_LINELIST             = 15,
304   D3DDP2OP_LINESTRIP            = 16,
305   D3DDP2OP_INDEXEDLINESTRIP     = 17,
306   D3DDP2OP_TRIANGLELIST         = 18,
307   D3DDP2OP_TRIANGLESTRIP        = 19,
308   D3DDP2OP_INDEXEDTRIANGLESTRIP = 20,
309   D3DDP2OP_TRIANGLEFAN          = 21,
310   D3DDP2OP_INDEXEDTRIANGLEFAN   = 22,
311   D3DDP2OP_TRIANGLEFAN_IMM      = 23,
312   D3DDP2OP_LINELIST_IMM         = 24,
313   D3DDP2OP_TEXTURESTAGESTATE    = 25,
314   D3DDP2OP_INDEXEDTRIANGLELIST2 = 26,
315   D3DDP2OP_INDEXEDLINELIST2     = 27,
316   D3DDP2OP_VIEWPORTINFO         = 28,
317   D3DDP2OP_WINFO                = 29,
318   /* pre-DirectX 7 interfaces */
319   D3DDP2OP_SETPALETTE           = 30,
320   D3DDP2OP_UPDATEPALETTE        = 31,
321   /* DirectX 7 interfaces */
322   D3DDP2OP_ZRANGE               = 32,
323   D3DDP2OP_SETMATERIAL          = 33,
324   D3DDP2OP_SETLIGHT             = 34,
325   D3DDP2OP_CREATELIGHT          = 35,
326   D3DDP2OP_SETTRANSFORM         = 36,
327   D3DDP2OP_TEXBLT               = 38,
328   D3DDP2OP_STATESET             = 39,
329   D3DDP2OP_SETPRIORITY          = 40,
330   /* all interfaces */
331   D3DDP2OP_SETRENDERTARGET      = 41,
332   D3DDP2OP_CLEAR                = 42,
333   /* DirectX 7 interfaces */
334   D3DDP2OP_SETTEXLOD            = 43,
335   D3DPP2OP_SETCLIPPLANE         = 44
336 } D3DHAL_DP2OPERATION;
337
338 /* point primitives */
339
340 typedef struct _D3DHAL_POINTS {
341   WORD wCount;
342   WORD wVStart;
343 } D3DHAL_DP2POINTS,*LPD3DHAL_DP2POINTS;
344
345 /* line primitives */
346
347 typedef struct _D3DHAL_DP2STARTVERTEX {
348   WORD wVStart;
349 } D3DHAL_DP2STARTVERTEX,*LPD3DHAL_DP2STARTVERTEX;
350
351 typedef struct _D3DHAL_DP2LINELIST {
352   WORD wVStart;
353 } D3DHAL_DP2LINELIST,*LPD3DHAL_DP2LINELIST;
354
355 typedef struct _D3DHAL_DP2INDEXEDLINELIST {
356   WORD wV1;
357   WORD wV2;
358 } D3DHAL_DP2INDEXEDLINELIST,*LPD3DHAL_DP2INDEXEDLINELIST;
359
360 typedef struct _D3DHAL_DP2LINESTRIP {
361   WORD wVStart;
362 } D3DHAL_DP2LINESTRIP,*LPD3DHAL_DP2LINESTRIP;
363
364 typedef struct _D3DHAL_DP2INDEXEDLINESTRIP {
365   WORD wV[2];
366 } D3DHAL_DP2INDEXEDLINESTRIP,*LPD3DHAL_DP2INDEXEDLINESTRIP;
367
368 /* triangle primitives */
369
370 typedef struct _D3DHAL_DP2TRIANGLELIST {
371   WORD wVStart;
372 } D3DHAL_DP2TRIANGLELIST,*LPD3DHAL_DP2TRIANGLELIST;
373
374 typedef struct _D3DHAL_DP2INDEXEDTRIANGLELIST {
375   WORD wV1;
376   WORD wV2;
377   WORD wV3;
378   WORD wFlags;
379 } D3DHAL_DP2INDEXEDTRIANGLELIST,*LPD3DHAL_DP2INDEXEDTRIANGLELIST;
380
381 typedef struct _D3DHAL_DP2INDEXEDTRIANGLELIST2 {
382   WORD wV1;
383   WORD wV2;
384   WORD wV3;
385 } D3DHAL_DP2INDEXEDTRIANGLELIST2,*LPD3DHAL_DP2INDEXEDTRIANGLELIST2;
386
387 typedef struct _D3DHAL_DP2TRIANGLESTRIP {
388   WORD wVStart;
389 } D3DHAL_DP2TRIANGLESTRIP,*LPD3DHAL_DP2TRIANGLESTRIP;
390
391 typedef struct _D3DHAL_DP2INDEXEDTRIANGLESTRIP {
392   WORD wV[3];
393 } D3DHAL_DP2INDEXEDTRIANGLESTRIP,*LPD3DHAL_DP2INDEXEDTRIANGLESTRIP;
394
395 typedef struct _D3DHAL_DP2TRIANGLEFAN {
396   WORD wVStart;
397 } D3DHAL_DP2TRIANGLEFAN,*LPD3DHAL_DP2TRIANGLEFAN;
398
399 typedef struct _D3DHAL_DP2INDEXEDTRIANGLEFAN {
400   WORD wV[3];
401 } D3DHAL_DP2INDEXEDTRIANGLEFAN,*LPD3DHAL_DP2INDEXEDTRIANGLEFAN;
402
403 typedef struct _D3DHAL_DP2TRIANGLEFAN_IMM {
404   DWORD dwEdgeFlags;
405 } D3DHAL_DP2TRIANGLEFAN_IMM,*LPD3DHAL_DP2TRIANGLEFAN_IMM;
406
407 /* render states */
408 typedef struct _D3DHAL_DP2RENDERSTATE {
409   D3DRENDERSTATETYPE    RenderState;
410   union {
411     D3DVALUE dvState;
412     DWORD dwState;
413   } DUMMYUNIONNAME;
414 } D3DHAL_DP2RENDERSTATE,*LPD3DHAL_DP2RENDERSTATE;
415
416 typedef struct _D3DHAL_DP2TEXTURESTAGESTATE {
417   WORD  wStage;
418   WORD  TSState;
419   DWORD dwValue;
420 } D3DHAL_DP2TEXTURESTAGESTATE,*LPD3DHAL_DP2TEXTURESTAGESTATE;
421
422 #define D3DTSS_TEXTUREMAP 0
423
424 typedef struct _D3DHAL_DP2VIEWPORTINFO {
425   DWORD dwX;
426   DWORD dwY;
427   DWORD dwWidth;
428   DWORD dwHeight;
429 } D3DHAL_DP2VIEWPORTINFO,*LPD3DHAL_DP2VIEWPORTINFO;
430
431 typedef struct _D3DHAL_DP2WINFO {
432   D3DVALUE dwWNear;
433   D3DVALUE dwWFar;
434 } D3DHAL_DP2WINFO,*LPD3DHAL_DP2WINFO;
435
436 typedef struct _D3DHAL_DP2SETPALETTE {
437   DWORD dwPaletteHandle;
438   DWORD dwPaletteFlags;
439   DWORD dwSurfaceHandle;
440 } D3DHAL_DP2SETPALETTE,*LPD3DHAL_DP2SETPALETTE;
441
442 typedef struct _D3DHAL_DP2UPDATEPALETTE {
443   DWORD dwPaletteHandle;
444   WORD  wStartIndex;
445   WORD  wNumEntries;
446 } D3DHAL_DP2UPDATEPALETTE,*LPD3DHAL_DP2UPDATEPALETTE;
447
448 typedef struct _D3DHAL_DP2ZRANGE {
449   D3DVALUE dvMinZ;
450   D3DVALUE dvMaxZ;
451 } D3DHAL_DP2ZRANGE,*LPD3DHAL_DP2ZRANGE;
452
453 typedef D3DMATERIAL7 D3DHAL_DP2SETMATERIAL,*LPD3DHAL_DP2SETMATERIAL;
454
455 typedef struct _D3DHAL_DP2SETLIGHT {
456   DWORD dwIndex;
457   DWORD dwDataType;
458 } D3DHAL_DP2SETLIGHT,*LPD3DHAL_DP2SETLIGHT;
459
460 #define D3DHAL_SETLIGHT_ENABLE  0
461 #define D3DHAL_SETLIGHT_DISABLE 1
462 #define D3DHAL_SETLIGHT_DATA    2
463
464 typedef struct _D3DHAL_DP2CREATELIGHT {
465   DWORD dwIndex;
466 } D3DHAL_DP2CREATELIGHT,*LPD3DHAL_DP2CREATELIGHT;
467
468 typedef struct _D3DHAL_DP2SETTRANSFORM {
469   D3DTRANSFORMSTATETYPE xfrmType;
470   D3DMATRIX             matrix;
471 } D3DHAL_DP2SETTRANSFORM,*LPD3DHAL_DP2SETTRANSFORM;
472
473 typedef struct _D3DHAL_DP2TEXBLT {
474   DWORD dwDDDestSurface;
475   DWORD dwDDSrcSurface;
476   POINT pDest;
477   RECTL rSrc;
478   DWORD dwFlags;
479 } D3DHAL_DP2TEXBLT,*LPD3DHAL_DP2TEXBLT;
480
481 typedef struct _D3DHAL_DP2STATESET {
482   DWORD               dwOperation;
483   DWORD               dwParam;
484   D3DSTATEBLOCKTYPE   sbType;
485 } D3DHAL_DP2STATESET,*LPD3DHAL_DP2STATESET;
486
487 #define D3DHAL_STATESETBEGIN    0
488 #define D3DHAL_STATESETEND      1
489 #define D3DHAL_STATESETDELETE   2
490 #define D3DHAL_STATESETEXECUTE  3
491 #define D3DHAL_STATESETCAPTURE  4
492
493 typedef struct _D3DHAL_DP2SETPRIORITY {
494   DWORD dwDDSurface;
495   DWORD dwPriority;
496 } D3DHAL_DP2SETPRIORITY,*LPD3DHAL_DP2SETPRIORITY;
497
498 typedef struct _D3DHAL_DP2SETRENDERTARGET {
499   DWORD hRenderTarget;
500   DWORD hZBuffer;
501 } D3DHAL_DP2SETRENDERTARGET,*LPD3DHAL_DP2SETRENDERTARGET;
502
503 typedef struct _D3DHAL_DP2CLEAR {
504   DWORD         dwFlags;
505   DWORD         dwFillColor;
506   D3DVALUE      dvFillDepth;
507   DWORD         dwFillStencil;
508   RECT          Rects[1];
509 } D3DHAL_DP2CLEAR,*LPD3DHAL_DP2CLEAR;
510
511 typedef struct _D3DHAL_DP2SETTEXLOD {
512   DWORD dwDDSurface;
513   DWORD dwLOD;
514 } D3DHAL_DP2SETTEXLOD,*LPD3DHAL_DP2SETTEXLOD;
515
516 #ifdef __cplusplus
517 } /* extern "C" */
518 #endif
519
520 #endif /* __WINE_D3DHAL_H */