wined3d: Silence some format spam.
[wine] / include / wine / wined3d_types.h
1 /*
2  * Direct3D wine types include file
3  *
4  * Copyright 2002-2003 The wine-d3d team
5  * Copyright 2002-2003 Jason Edmeades
6  *                     Raphael Junqueira
7  * Copyright 2005 Oliver Stieber
8  * Copyright 2006 Stefan Dösinger
9  *
10  * This library is free software; you can redistribute it and/or
11  * modify it under the terms of the GNU Lesser General Public
12  * License as published by the Free Software Foundation; either
13  * version 2.1 of the License, or (at your option) any later version.
14  *
15  * This library is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
18  * Lesser General Public License for more details.
19  *
20  * You should have received a copy of the GNU Lesser General Public
21  * License along with this library; if not, write to the Free Software
22  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
23  */
24
25 #ifndef __WINE_WINED3D_TYPES_H
26 #define __WINE_WINED3D_TYPES_H
27
28 typedef DWORD WINED3DCOLOR;
29
30 typedef enum _WINED3DLIGHTTYPE {
31   WINED3DLIGHT_POINT          = 1,
32   WINED3DLIGHT_SPOT           = 2,
33   WINED3DLIGHT_DIRECTIONAL    = 3,
34   WINED3DLIGHT_PARALLELPOINT  = 4, /* D3D7 */
35   WINED3DLIGHT_GLSPOT         = 5, /* D3D7 */
36   WINED3DLIGHT_FORCE_DWORD    = 0x7fffffff
37 } WINED3DLIGHTTYPE;
38
39 typedef enum _WINED3DPRIMITIVETYPE {
40     WINED3DPT_POINTLIST       = 1,
41     WINED3DPT_LINELIST        = 2,
42     WINED3DPT_LINESTRIP       = 3,
43     WINED3DPT_TRIANGLELIST    = 4,
44     WINED3DPT_TRIANGLESTRIP   = 5,
45     WINED3DPT_TRIANGLEFAN     = 6,
46
47     WINED3DPT_FORCE_DWORD     = 0x7fffffff
48 } WINED3DPRIMITIVETYPE;
49
50 typedef struct _WINED3DCOLORVALUE {
51     float r;
52     float g;
53     float b;
54     float a;
55 } WINED3DCOLORVALUE;
56
57 typedef struct _WINED3DVECTOR {
58     float x;
59     float y;
60     float z;
61 } WINED3DVECTOR;
62
63 typedef struct _WINED3DMATRIX {
64     union {
65         struct {
66             float        _11, _12, _13, _14;
67             float        _21, _22, _23, _24;
68             float        _31, _32, _33, _34;
69             float        _41, _42, _43, _44;
70         } DUMMYSTRUCTNAME;
71         float m[4][4];
72     } DUMMYUNIONNAME;
73 } WINED3DMATRIX;
74
75 typedef struct _WINED3DRECT {
76     LONG x1;
77     LONG y1;
78     LONG x2;
79     LONG y2;
80 } WINED3DRECT;
81
82 typedef struct _WINED3DLIGHT {
83     WINED3DLIGHTTYPE    Type;
84     WINED3DCOLORVALUE   Diffuse;
85     WINED3DCOLORVALUE   Specular;
86     WINED3DCOLORVALUE   Ambient;
87     WINED3DVECTOR       Position;
88     WINED3DVECTOR       Direction;
89     float               Range;
90     float               Falloff;
91     float               Attenuation0;
92     float               Attenuation1;
93     float               Attenuation2;
94     float               Theta;
95     float               Phi;
96 } WINED3DLIGHT;
97
98 typedef struct _WINED3DMATERIAL {
99     WINED3DCOLORVALUE   Diffuse;
100     WINED3DCOLORVALUE   Ambient;
101     WINED3DCOLORVALUE   Specular;
102     WINED3DCOLORVALUE   Emissive;
103     float           Power;
104 } WINED3DMATERIAL;
105
106 typedef struct _WINED3DVIEWPORT {
107     DWORD       X;
108     DWORD       Y;
109     DWORD       Width;
110     DWORD       Height;
111     float       MinZ;
112     float       MaxZ;
113 } WINED3DVIEWPORT;
114
115 typedef struct _WINED3DGAMMARAMP {
116     WORD                red  [256];
117     WORD                green[256];
118     WORD                blue [256];
119 } WINED3DGAMMARAMP;
120
121 typedef struct _WINED3DLINEPATTERN {
122     WORD    wRepeatFactor;
123     WORD    wLinePattern;
124 } WINED3DLINEPATTERN;
125
126 #define WINED3D_VSHADER_MAX_CONSTANTS 96
127 #define WINED3D_PSHADER_MAX_CONSTANTS 32
128
129 typedef struct _WINED3DVECTOR_3 {
130     float x;
131     float y;
132     float z;
133 } WINED3DVECTOR_3;
134
135 typedef struct _WINED3DVECTOR_4 {
136     float x;
137     float y;
138     float z;
139     float w;
140 } WINED3DVECTOR_4;
141
142 typedef struct WINED3DSHADERVECTOR {
143   float x;
144   float y;
145   float z;
146   float w;
147 } WINED3DSHADERVECTOR;
148
149 typedef struct WINED3DSHADERSCALAR {
150   float x;
151 } WINED3DSHADERSCALAR;
152
153 typedef WINED3DSHADERVECTOR WINEVSHADERCONSTANTS8[WINED3D_VSHADER_MAX_CONSTANTS];
154
155 typedef struct VSHADERDATA {
156   /** Run Time Shader Function Constants */
157   /*D3DXBUFFER* constants;*/
158   WINEVSHADERCONSTANTS8 C;
159   /** Shader Code as char ... */
160   CONST DWORD* code;
161   UINT codeLength;
162 } VSHADERDATA;
163
164 /** temporary here waiting for buffer code */
165 typedef struct VSHADERINPUTDATA {
166   WINED3DSHADERVECTOR V[17];
167 } WINEVSHADERINPUTDATA;
168
169 /** temporary here waiting for buffer code */
170 typedef struct VSHADEROUTPUTDATA {
171   WINED3DSHADERVECTOR oPos;
172   WINED3DSHADERVECTOR oD[2];
173   WINED3DSHADERVECTOR oT[8];
174   WINED3DSHADERVECTOR oFog;
175   WINED3DSHADERVECTOR oPts;
176 } WINEVSHADEROUTPUTDATA;
177
178 typedef WINED3DSHADERVECTOR WINEPSHADERCONSTANTS8[WINED3D_PSHADER_MAX_CONSTANTS];
179
180 typedef struct PSHADERDATA {
181   /** Run Time Shader Function Constants */
182   /*D3DXBUFFER* constants;*/
183   WINEPSHADERCONSTANTS8 C;
184   /** Shader Code as char ... */
185   CONST DWORD* code;
186   UINT codeLength;
187 } PSHADERDATA;
188
189 /** temporary here waiting for buffer code */
190 typedef struct PSHADERINPUTDATA {
191   WINED3DSHADERVECTOR V[2];
192   WINED3DSHADERVECTOR T[8];
193   WINED3DSHADERVECTOR S[16];
194   /*D3DSHADERVECTOR R[12];*/
195 } WINEPSHADERINPUTDATA;
196
197 /** temporary here waiting for buffer code */
198 typedef struct PSHADEROUTPUTDATA {
199   WINED3DSHADERVECTOR oC[4];
200   WINED3DSHADERVECTOR oDepth;
201 } WINEPSHADEROUTPUTDATA;
202
203 /*****************************************************************************
204  * WineD3D Structures to be used when d3d8 and d3d9 are incompatible
205  */
206
207
208 typedef enum _WINED3DDEVTYPE {
209     WINED3DDEVTYPE_HAL         = 1,
210     WINED3DDEVTYPE_REF         = 2,
211     WINED3DDEVTYPE_SW          = 3,
212     WINED3DDEVTYPE_NULLREF     = 4,
213
214     WINED3DDEVTYPE_FORCE_DWORD = 0xffffffff
215 } WINED3DDEVTYPE;
216
217 typedef enum _WINED3DDEGREETYPE {
218     WINED3DDEGREE_LINEAR      = 1,
219     WINED3DDEGREE_QUADRATIC   = 2,
220     WINED3DDEGREE_CUBIC       = 3,
221     WINED3DDEGREE_QUINTIC     = 5,
222     
223     WINED3DDEGREE_FORCE_DWORD   = 0x7fffffff
224 } WINED3DDEGREETYPE;
225
226 #define WINEMAKEFOURCC(ch0, ch1, ch2, ch3)  \
227     ((DWORD)(BYTE)(ch0) | ((DWORD)(BYTE)(ch1) << 8) |  \
228     ((DWORD)(BYTE)(ch2) << 16) | ((DWORD)(BYTE)(ch3) << 24 ))
229
230 typedef enum _WINED3DFORMAT {
231     WINED3DFMT_UNKNOWN              =   0,
232
233     WINED3DFMT_R8G8B8               =  20,
234     WINED3DFMT_A8R8G8B8             =  21,
235     WINED3DFMT_X8R8G8B8             =  22,
236     WINED3DFMT_R5G6B5               =  23,
237     WINED3DFMT_X1R5G5B5             =  24,
238     WINED3DFMT_A1R5G5B5             =  25,
239     WINED3DFMT_A4R4G4B4             =  26,
240     WINED3DFMT_R3G3B2               =  27,
241     WINED3DFMT_A8                   =  28,
242     WINED3DFMT_A8R3G3B2             =  29,
243     WINED3DFMT_X4R4G4B4             =  30,
244     WINED3DFMT_A2B10G10R10          =  31,
245     WINED3DFMT_A8B8G8R8             =  32,
246     WINED3DFMT_X8B8G8R8             =  33,
247     WINED3DFMT_G16R16               =  34,
248     WINED3DFMT_A2R10G10B10          =  35,
249     WINED3DFMT_A16B16G16R16         =  36,
250   
251
252     WINED3DFMT_A8P8                 =  40,
253     WINED3DFMT_P8                   =  41,
254
255     WINED3DFMT_L8                   =  50,
256     WINED3DFMT_A8L8                 =  51,
257     WINED3DFMT_A4L4                 =  52,
258
259     WINED3DFMT_V8U8                 =  60,
260     WINED3DFMT_L6V5U5               =  61,
261     WINED3DFMT_X8L8V8U8             =  62,
262     WINED3DFMT_Q8W8V8U8             =  63,
263     WINED3DFMT_V16U16               =  64,
264     WINED3DFMT_W11V11U10            =  65,
265     WINED3DFMT_A2W10V10U10          =  67,
266
267     WINED3DFMT_UYVY                 =  WINEMAKEFOURCC('U', 'Y', 'V', 'Y'),
268     WINED3DFMT_YUY2                 =  WINEMAKEFOURCC('Y', 'U', 'Y', '2'),
269     WINED3DFMT_YV12                 =  WINEMAKEFOURCC('Y', 'V', '1', '2'),
270     WINED3DFMT_DXT1                 =  WINEMAKEFOURCC('D', 'X', 'T', '1'),
271     WINED3DFMT_DXT2                 =  WINEMAKEFOURCC('D', 'X', 'T', '2'),
272     WINED3DFMT_DXT3                 =  WINEMAKEFOURCC('D', 'X', 'T', '3'),
273     WINED3DFMT_DXT4                 =  WINEMAKEFOURCC('D', 'X', 'T', '4'),
274     WINED3DFMT_DXT5                 =  WINEMAKEFOURCC('D', 'X', 'T', '5'),
275     WINED3DFMT_MULTI2_ARGB8         =  WINEMAKEFOURCC('M', 'E', 'T', '1'),
276     WINED3DFMT_G8R8_G8B8            =  WINEMAKEFOURCC('G', 'R', 'G', 'B'),
277     WINED3DFMT_R8G8_B8G8            =  WINEMAKEFOURCC('R', 'G', 'B', 'G'),
278
279     WINED3DFMT_D16_LOCKABLE         =  70,
280     WINED3DFMT_D32                  =  71,
281     WINED3DFMT_D15S1                =  73,
282     WINED3DFMT_D24S8                =  75,
283     WINED3DFMT_D24X8                =  77,
284     WINED3DFMT_D24X4S4              =  79,
285     WINED3DFMT_D16                  =  80,
286     WINED3DFMT_L16                  =  81,
287     WINED3DFMT_D32F_LOCKABLE        =  82,
288     WINED3DFMT_D24FS8               =  83,
289
290     WINED3DFMT_VERTEXDATA           = 100,
291     WINED3DFMT_INDEX16              = 101,
292     WINED3DFMT_INDEX32              = 102,
293     WINED3DFMT_Q16W16V16U16         = 110,
294     /* Floating point formats */
295     WINED3DFMT_R16F                 = 111,
296     WINED3DFMT_G16R16F              = 112,
297     WINED3DFMT_A16B16G16R16F        = 113,
298     
299     /* IEEE formats */
300     WINED3DFMT_R32F                 = 114,
301     WINED3DFMT_G32R32F              = 115,
302     WINED3DFMT_A32B32G32R32F        = 116,
303     
304     WINED3DFMT_CxV8U8               = 117,
305
306     /* Vendor specific formats */
307     WINED3DFMT_ATI2N                =  WINEMAKEFOURCC('A', 'T', 'I', '2'),
308     WINED3DFMT_NVHU                 =  WINEMAKEFOURCC('N', 'V', 'H', 'U'),
309     WINED3DFMT_NVHS                 =  WINEMAKEFOURCC('N', 'V', 'H', 'S'),
310
311     WINED3DFMT_FORCE_DWORD          = 0xFFFFFFFF
312 } WINED3DFORMAT;
313
314 typedef enum _WINED3DRENDERSTATETYPE {
315     WINED3DRS_TEXTUREHANDLE             =   1, /* d3d7 */
316     WINED3DRS_ANTIALIAS                 =   2, /* d3d7 */
317     WINED3DRS_TEXTUREADDRESS            =   3, /* d3d7 */
318     WINED3DRS_TEXTUREPERSPECTIVE        =   4, /* d3d7 */
319     WINED3DRS_WRAPU                     =   5, /* d3d7 */
320     WINED3DRS_WRAPV                     =   6, /* d3d7 */
321     WINED3DRS_ZENABLE                   =   7,
322     WINED3DRS_FILLMODE                  =   8,
323     WINED3DRS_SHADEMODE                 =   9,
324     WINED3DRS_LINEPATTERN               =  10, /* d3d7, d3d8 */
325     WINED3DRS_MONOENABLE                =  11, /* d3d7 */
326     WINED3DRS_ROP2                      =  12, /* d3d7 */
327     WINED3DRS_PLANEMASK                 =  13, /* d3d7 */
328     WINED3DRS_ZWRITEENABLE              =  14,
329     WINED3DRS_ALPHATESTENABLE           =  15,
330     WINED3DRS_LASTPIXEL                 =  16,
331     WINED3DRS_TEXTUREMAG                =  17, /* d3d7 */
332     WINED3DRS_TEXTUREMIN                =  18, /* d3d7 */
333     WINED3DRS_SRCBLEND                  =  19,
334     WINED3DRS_DESTBLEND                 =  20,
335     WINED3DRS_TEXTUREMAPBLEND           =  21, /* d3d7 */
336     WINED3DRS_CULLMODE                  =  22,
337     WINED3DRS_ZFUNC                     =  23,
338     WINED3DRS_ALPHAREF                  =  24,
339     WINED3DRS_ALPHAFUNC                 =  25,
340     WINED3DRS_DITHERENABLE              =  26,
341     WINED3DRS_ALPHABLENDENABLE          =  27,
342     WINED3DRS_FOGENABLE                 =  28,
343     WINED3DRS_SPECULARENABLE            =  29,
344     WINED3DRS_ZVISIBLE                  =  30, /* d3d7, d3d8 */
345     WINED3DRS_SUBPIXEL                  =  31, /* d3d7 */
346     WINED3DRS_SUBPIXELX                 =  32, /* d3d7 */
347     WINED3DRS_STIPPLEDALPHA             =  33, /* d3d7 */
348     WINED3DRS_FOGCOLOR                  =  34,
349     WINED3DRS_FOGTABLEMODE              =  35,
350     WINED3DRS_FOGSTART                  =  36,
351     WINED3DRS_FOGEND                    =  37,
352     WINED3DRS_FOGDENSITY                =  38,
353     WINED3DRS_STIPPLEENABLE             =  39, /* d3d7 */
354     WINED3DRS_EDGEANTIALIAS             =  40, /* d3d7, d3d8 */
355     WINED3DRS_COLORKEYENABLE            =  41, /* d3d7 */
356     WINED3DRS_BORDERCOLOR               =  43, /* d3d7 */
357     WINED3DRS_TEXTUREADDRESSU           =  44, /* d3d7 */
358     WINED3DRS_TEXTUREADDRESSV           =  45, /* d3d7 */
359     WINED3DRS_MIPMAPLODBIAS             =  46, /* d3d7 */
360     WINED3DRS_ZBIAS                     =  47, /* d3d7, d3d8 */
361     WINED3DRS_RANGEFOGENABLE            =  48,
362     WINED3DRS_ANISOTROPY                =  49, /* d3d7 */
363     WINED3DRS_FLUSHBATCH                =  50, /* d3d7 */
364     WINED3DRS_TRANSLUCENTSORTINDEPENDENT = 51, /* d3d7 */
365     WINED3DRS_STENCILENABLE             =  52,
366     WINED3DRS_STENCILFAIL               =  53,
367     WINED3DRS_STENCILZFAIL              =  54,
368     WINED3DRS_STENCILPASS               =  55,
369     WINED3DRS_STENCILFUNC               =  56,
370     WINED3DRS_STENCILREF                =  57,
371     WINED3DRS_STENCILMASK               =  58,
372     WINED3DRS_STENCILWRITEMASK          =  59,
373     WINED3DRS_TEXTUREFACTOR             =  60,
374
375     WINED3DRS_STIPPLEPATTERN00          = 64,
376     WINED3DRS_STIPPLEPATTERN01          = 65,
377     WINED3DRS_STIPPLEPATTERN02          = 66,
378     WINED3DRS_STIPPLEPATTERN03          = 67,
379     WINED3DRS_STIPPLEPATTERN04          = 68,
380     WINED3DRS_STIPPLEPATTERN05          = 69,
381     WINED3DRS_STIPPLEPATTERN06          = 70,
382     WINED3DRS_STIPPLEPATTERN07          = 71,
383     WINED3DRS_STIPPLEPATTERN08          = 72,
384     WINED3DRS_STIPPLEPATTERN09          = 73,
385     WINED3DRS_STIPPLEPATTERN10          = 74,
386     WINED3DRS_STIPPLEPATTERN11          = 75,
387     WINED3DRS_STIPPLEPATTERN12          = 76,
388     WINED3DRS_STIPPLEPATTERN13          = 77,
389     WINED3DRS_STIPPLEPATTERN14          = 78,
390     WINED3DRS_STIPPLEPATTERN15          = 79,
391     WINED3DRS_STIPPLEPATTERN16          = 80,
392     WINED3DRS_STIPPLEPATTERN17          = 81,
393     WINED3DRS_STIPPLEPATTERN18          = 82,
394     WINED3DRS_STIPPLEPATTERN19          = 83,
395     WINED3DRS_STIPPLEPATTERN20          = 84,
396     WINED3DRS_STIPPLEPATTERN21          = 85,
397     WINED3DRS_STIPPLEPATTERN22          = 86,
398     WINED3DRS_STIPPLEPATTERN23          = 87,
399     WINED3DRS_STIPPLEPATTERN24          = 88,
400     WINED3DRS_STIPPLEPATTERN25          = 89,
401     WINED3DRS_STIPPLEPATTERN26          = 90,
402     WINED3DRS_STIPPLEPATTERN27          = 91,
403     WINED3DRS_STIPPLEPATTERN28          = 92,
404     WINED3DRS_STIPPLEPATTERN29          = 93,
405     WINED3DRS_STIPPLEPATTERN30          = 94,
406     WINED3DRS_STIPPLEPATTERN31          = 95,
407
408     WINED3DRS_WRAP0                     = 128,
409     WINED3DRS_WRAP1                     = 129,
410     WINED3DRS_WRAP2                     = 130,
411     WINED3DRS_WRAP3                     = 131,
412     WINED3DRS_WRAP4                     = 132,
413     WINED3DRS_WRAP5                     = 133,
414     WINED3DRS_WRAP6                     = 134,
415     WINED3DRS_WRAP7                     = 135,
416     WINED3DRS_CLIPPING                  = 136,
417     WINED3DRS_LIGHTING                  = 137,
418     WINED3DRS_EXTENTS                   = 138, /* d3d7 */
419     WINED3DRS_AMBIENT                   = 139,
420     WINED3DRS_FOGVERTEXMODE             = 140,
421     WINED3DRS_COLORVERTEX               = 141,
422     WINED3DRS_LOCALVIEWER               = 142,
423     WINED3DRS_NORMALIZENORMALS          = 143,
424     WINED3DRS_COLORKEYBLENDENABLE       = 144, /* d3d7 */
425     WINED3DRS_DIFFUSEMATERIALSOURCE     = 145,
426     WINED3DRS_SPECULARMATERIALSOURCE    = 146,
427     WINED3DRS_AMBIENTMATERIALSOURCE     = 147,
428     WINED3DRS_EMISSIVEMATERIALSOURCE    = 148,
429     WINED3DRS_VERTEXBLEND               = 151,
430     WINED3DRS_CLIPPLANEENABLE           = 152,  
431     WINED3DRS_SOFTWAREVERTEXPROCESSING  = 153, /* d3d8 */
432     WINED3DRS_POINTSIZE                 = 154,
433     WINED3DRS_POINTSIZE_MIN             = 155,
434     WINED3DRS_POINTSPRITEENABLE         = 156,
435     WINED3DRS_POINTSCALEENABLE          = 157,
436     WINED3DRS_POINTSCALE_A              = 158,
437     WINED3DRS_POINTSCALE_B              = 159,
438     WINED3DRS_POINTSCALE_C              = 160,
439     WINED3DRS_MULTISAMPLEANTIALIAS      = 161,
440     WINED3DRS_MULTISAMPLEMASK           = 162,
441     WINED3DRS_PATCHEDGESTYLE            = 163,
442     WINED3DRS_PATCHSEGMENTS             = 164, /* d3d8 */
443     WINED3DRS_DEBUGMONITORTOKEN         = 165,
444     WINED3DRS_POINTSIZE_MAX             = 166,
445     WINED3DRS_INDEXEDVERTEXBLENDENABLE  = 167,
446     WINED3DRS_COLORWRITEENABLE          = 168,
447     WINED3DRS_TWEENFACTOR               = 170,
448     WINED3DRS_BLENDOP                   = 171,
449     WINED3DRS_POSITIONORDER             = 172,
450     WINED3DRS_NORMALORDER               = 173,
451     WINED3DRS_POSITIONDEGREE            = 172,
452     WINED3DRS_NORMALDEGREE              = 173,
453     WINED3DRS_SCISSORTESTENABLE         = 174,
454     WINED3DRS_SLOPESCALEDEPTHBIAS       = 175,
455     WINED3DRS_ANTIALIASEDLINEENABLE     = 176,
456     WINED3DRS_MINTESSELLATIONLEVEL      = 178,
457     WINED3DRS_MAXTESSELLATIONLEVEL      = 179,
458     WINED3DRS_ADAPTIVETESS_X            = 180,
459     WINED3DRS_ADAPTIVETESS_Y            = 181,
460     WINED3DRS_ADAPTIVETESS_Z            = 182,
461     WINED3DRS_ADAPTIVETESS_W            = 183,
462     WINED3DRS_ENABLEADAPTIVETESSELLATION= 184,
463     WINED3DRS_TWOSIDEDSTENCILMODE       = 185,
464     WINED3DRS_CCW_STENCILFAIL           = 186,
465     WINED3DRS_CCW_STENCILZFAIL          = 187,
466     WINED3DRS_CCW_STENCILPASS           = 188,
467     WINED3DRS_CCW_STENCILFUNC           = 189,
468     WINED3DRS_COLORWRITEENABLE1         = 190,
469     WINED3DRS_COLORWRITEENABLE2         = 191,
470     WINED3DRS_COLORWRITEENABLE3         = 192,
471     WINED3DRS_BLENDFACTOR               = 193,
472     WINED3DRS_SRGBWRITEENABLE           = 194,
473     WINED3DRS_DEPTHBIAS                 = 195,
474     WINED3DRS_WRAP8                     = 198,
475     WINED3DRS_WRAP9                     = 199,
476     WINED3DRS_WRAP10                    = 200,
477     WINED3DRS_WRAP11                    = 201,
478     WINED3DRS_WRAP12                    = 202,
479     WINED3DRS_WRAP13                    = 203,
480     WINED3DRS_WRAP14                    = 204,
481     WINED3DRS_WRAP15                    = 205,
482     WINED3DRS_SEPARATEALPHABLENDENABLE  = 206,
483     WINED3DRS_SRCBLENDALPHA             = 207,
484     WINED3DRS_DESTBLENDALPHA            = 208,
485     WINED3DRS_BLENDOPALPHA              = 209,
486
487     WINED3DRS_FORCE_DWORD               = 0x7fffffff
488 } WINED3DRENDERSTATETYPE;
489
490 #define WINEHIGHEST_RENDER_STATE   WINED3DRS_BLENDOPALPHA
491         /* Highest WINED3DRS_ value   */
492
493 #define WINED3DCOLORWRITEENABLE_RED   (1<<0)
494 #define WINED3DCOLORWRITEENABLE_GREEN (1<<1)
495 #define WINED3DCOLORWRITEENABLE_BLUE  (1<<2)
496 #define WINED3DCOLORWRITEENABLE_ALPHA (1<<3)
497
498 typedef enum _WINED3DBLEND {
499     WINED3DBLEND_ZERO               =  1,
500     WINED3DBLEND_ONE                =  2,
501     WINED3DBLEND_SRCCOLOR           =  3,
502     WINED3DBLEND_INVSRCCOLOR        =  4,
503     WINED3DBLEND_SRCALPHA           =  5,
504     WINED3DBLEND_INVSRCALPHA        =  6,
505     WINED3DBLEND_DESTALPHA          =  7,
506     WINED3DBLEND_INVDESTALPHA       =  8,
507     WINED3DBLEND_DESTCOLOR          =  9,
508     WINED3DBLEND_INVDESTCOLOR       = 10,
509     WINED3DBLEND_SRCALPHASAT        = 11,
510     WINED3DBLEND_BOTHSRCALPHA       = 12,
511     WINED3DBLEND_BOTHINVSRCALPHA    = 13,
512     WINED3DBLEND_BLENDFACTOR        = 14,
513     WINED3DBLEND_INVBLENDFACTOR     = 15,
514     WINED3DBLEND_FORCE_DWORD        = 0x7fffffff
515 } WINED3DBLEND;
516
517 typedef enum _WINED3DBLENDOP {
518     WINED3DBLENDOP_ADD              = 1,
519     WINED3DBLENDOP_SUBTRACT         = 2,
520     WINED3DBLENDOP_REVSUBTRACT      = 3,
521     WINED3DBLENDOP_MIN              = 4,
522     WINED3DBLENDOP_MAX              = 5,
523
524     WINED3DBLENDOP_FORCE_DWORD      = 0x7fffffff
525 } WINED3DBLENDOP;
526
527 typedef enum _WINED3DVERTEXBLENDFLAGS {
528     WINED3DVBF_DISABLE  =   0,
529     WINED3DVBF_1WEIGHTS =   1,
530     WINED3DVBF_2WEIGHTS =   2,
531     WINED3DVBF_3WEIGHTS =   3,
532     WINED3DVBF_TWEENING = 255,
533     WINED3DVBF_0WEIGHTS = 256
534 } WINED3DVERTEXBLENDFLAGS;
535
536 typedef enum _WINED3DCMPFUNC {
537     WINED3DCMP_NEVER                = 1,
538     WINED3DCMP_LESS                 = 2,
539     WINED3DCMP_EQUAL                = 3,
540     WINED3DCMP_LESSEQUAL            = 4,
541     WINED3DCMP_GREATER              = 5,
542     WINED3DCMP_NOTEQUAL             = 6,
543     WINED3DCMP_GREATEREQUAL         = 7,
544     WINED3DCMP_ALWAYS               = 8,
545
546     WINED3DCMP_FORCE_DWORD          = 0x7fffffff
547 } WINED3DCMPFUNC;
548
549 typedef enum _WINED3DZBUFFERTYPE {
550     WINED3DZB_FALSE                 = 0,
551     WINED3DZB_TRUE                  = 1,
552     WINED3DZB_USEW                  = 2,
553
554     WINED3DZB_FORCE_DWORD           = 0x7fffffff
555 } WINED3DZBUFFERTYPE;
556
557 typedef enum _WINED3DFOGMODE {
558     WINED3DFOG_NONE                 = 0,
559     WINED3DFOG_EXP                  = 1,
560     WINED3DFOG_EXP2                 = 2,
561     WINED3DFOG_LINEAR               = 3,
562
563     WINED3DFOG_FORCE_DWORD          = 0x7fffffff
564 } WINED3DFOGMODE;
565
566 typedef enum _WINED3DSHADEMODE {
567     WINED3DSHADE_FLAT               = 1,
568     WINED3DSHADE_GOURAUD            = 2,
569     WINED3DSHADE_PHONG              = 3,
570
571     WINED3DSHADE_FORCE_DWORD        = 0x7fffffff
572 } WINED3DSHADEMODE;
573
574 typedef enum _WINED3DFILLMODE {
575     WINED3DFILL_POINT               = 1,
576     WINED3DFILL_WIREFRAME           = 2,
577     WINED3DFILL_SOLID               = 3,
578
579     WINED3DFILL_FORCE_DWORD         = 0x7fffffff
580 } WINED3DFILLMODE;
581
582 typedef enum _WINED3DCULL {
583     WINED3DCULL_NONE                = 1,
584     WINED3DCULL_CW                  = 2,
585     WINED3DCULL_CCW                 = 3,
586
587     WINED3DCULL_FORCE_DWORD         = 0x7fffffff
588 } WINED3DCULL;
589
590 typedef enum _WINED3DSTENCILOP {
591     WINED3DSTENCILOP_KEEP           = 1,
592     WINED3DSTENCILOP_ZERO           = 2,
593     WINED3DSTENCILOP_REPLACE        = 3,
594     WINED3DSTENCILOP_INCRSAT        = 4,
595     WINED3DSTENCILOP_DECRSAT        = 5,
596     WINED3DSTENCILOP_INVERT         = 6,
597     WINED3DSTENCILOP_INCR           = 7,
598     WINED3DSTENCILOP_DECR           = 8,
599
600     WINED3DSTENCILOP_FORCE_DWORD    = 0x7fffffff
601 } WINED3DSTENCILOP;
602
603 typedef enum _WINED3DMATERIALCOLORSOURCE {
604     WINED3DMCS_MATERIAL         = 0,
605     WINED3DMCS_COLOR1           = 1,
606     WINED3DMCS_COLOR2           = 2,
607
608     WINED3DMCS_FORCE_DWORD      = 0x7fffffff
609 } WINED3DMATERIALCOLORSOURCE;
610
611 typedef enum _WINED3DPATCHEDGESTYLE {
612    WINED3DPATCHEDGE_DISCRETE    = 0,
613    WINED3DPATCHEDGE_CONTINUOUS  = 1,
614
615    WINED3DPATCHEDGE_FORCE_DWORD = 0x7fffffff,
616 } WINED3DPATCHEDGESTYLE;
617
618 typedef struct _WINED3DDISPLAYMODE {
619     UINT            Width;
620     UINT            Height;
621     UINT            RefreshRate;
622     WINED3DFORMAT   Format;
623 } WINED3DDISPLAYMODE;
624
625 typedef enum _WINED3DBACKBUFFER_TYPE {
626     WINED3DBACKBUFFER_TYPE_MONO         = 0,
627     WINED3DBACKBUFFER_TYPE_LEFT         = 1,
628     WINED3DBACKBUFFER_TYPE_RIGHT        = 2,
629
630     WINED3DBACKBUFFER_TYPE_FORCE_DWORD  = 0x7fffffff
631 } WINED3DBACKBUFFER_TYPE;
632
633 #define WINED3DADAPTER_DEFAULT          0
634 #define WINED3DENUM_NO_WHQL_LEVEL       2
635 #define WINED3DPRESENT_BACK_BUFFER_MAX  3
636
637 typedef enum _WINED3DSWAPEFFECT {
638     WINED3DSWAPEFFECT_DISCARD         = 1,
639     WINED3DSWAPEFFECT_FLIP            = 2,
640     WINED3DSWAPEFFECT_COPY            = 3,
641     WINED3DSWAPEFFECT_COPY_VSYNC      = 4,
642     WINED3DSWAPEFFECT_FORCE_DWORD     = 0xFFFFFFFF
643 } WINED3DSWAPEFFECT;
644
645 typedef enum _WINED3DSAMPLERSTATETYPE {
646     WINED3DSAMP_ADDRESSU       = 1,
647     WINED3DSAMP_ADDRESSV       = 2,
648     WINED3DSAMP_ADDRESSW       = 3,
649     WINED3DSAMP_BORDERCOLOR    = 4,
650     WINED3DSAMP_MAGFILTER      = 5,
651     WINED3DSAMP_MINFILTER      = 6,
652     WINED3DSAMP_MIPFILTER      = 7,
653     WINED3DSAMP_MIPMAPLODBIAS  = 8,
654     WINED3DSAMP_MAXMIPLEVEL    = 9,
655     WINED3DSAMP_MAXANISOTROPY  = 10,
656     WINED3DSAMP_SRGBTEXTURE    = 11,
657     WINED3DSAMP_ELEMENTINDEX   = 12,
658     WINED3DSAMP_DMAPOFFSET     = 13,
659
660     WINED3DSAMP_FORCE_DWORD   = 0x7fffffff,
661 } WINED3DSAMPLERSTATETYPE;
662 #define WINED3D_HIGHEST_SAMPLER_STATE WINED3DSAMP_DMAPOFFSET
663
664 typedef enum _WINED3DMULTISAMPLE_TYPE {
665     WINED3DMULTISAMPLE_NONE          =  0,
666     WINED3DMULTISAMPLE_NONMASKABLE   =  1,
667     WINED3DMULTISAMPLE_2_SAMPLES     =  2,
668     WINED3DMULTISAMPLE_3_SAMPLES     =  3,
669     WINED3DMULTISAMPLE_4_SAMPLES     =  4,
670     WINED3DMULTISAMPLE_5_SAMPLES     =  5,
671     WINED3DMULTISAMPLE_6_SAMPLES     =  6,
672     WINED3DMULTISAMPLE_7_SAMPLES     =  7,
673     WINED3DMULTISAMPLE_8_SAMPLES     =  8,
674     WINED3DMULTISAMPLE_9_SAMPLES     =  9,
675     WINED3DMULTISAMPLE_10_SAMPLES    = 10,
676     WINED3DMULTISAMPLE_11_SAMPLES    = 11,
677     WINED3DMULTISAMPLE_12_SAMPLES    = 12,
678     WINED3DMULTISAMPLE_13_SAMPLES    = 13,
679     WINED3DMULTISAMPLE_14_SAMPLES    = 14,
680     WINED3DMULTISAMPLE_15_SAMPLES    = 15,
681     WINED3DMULTISAMPLE_16_SAMPLES    = 16,
682
683     WINED3DMULTISAMPLE_FORCE_DWORD   = 0xffffffff
684 } WINED3DMULTISAMPLE_TYPE;
685
686 typedef enum _WINED3DTEXTURESTAGESTATETYPE {
687     WINED3DTSS_COLOROP               =  1,
688     WINED3DTSS_COLORARG1             =  2,
689     WINED3DTSS_COLORARG2             =  3,
690     WINED3DTSS_ALPHAOP               =  4,
691     WINED3DTSS_ALPHAARG1             =  5,
692     WINED3DTSS_ALPHAARG2             =  6,
693     WINED3DTSS_BUMPENVMAT00          =  7,
694     WINED3DTSS_BUMPENVMAT01          =  8,
695     WINED3DTSS_BUMPENVMAT10          =  9,
696     WINED3DTSS_BUMPENVMAT11          = 10,
697     WINED3DTSS_TEXCOORDINDEX         = 11,
698     WINED3DTSS_ADDRESS               = 12,
699     WINED3DTSS_ADDRESSU              = 13,
700     WINED3DTSS_ADDRESSV              = 14,
701     WINED3DTSS_BORDERCOLOR           = 15,
702     WINED3DTSS_MAGFILTER             = 16,
703     WINED3DTSS_MINFILTER             = 17,
704     WINED3DTSS_MIPFILTER             = 18,
705     WINED3DTSS_MIPMAPLODBIAS         = 19,
706     WINED3DTSS_MAXMIPLEVEL           = 20,
707     WINED3DTSS_MAXANISOTROPY         = 21,
708     WINED3DTSS_BUMPENVLSCALE         = 22,
709     WINED3DTSS_BUMPENVLOFFSET        = 23,
710     WINED3DTSS_TEXTURETRANSFORMFLAGS = 24,
711     WINED3DTSS_ADDRESSW              = 25,
712     WINED3DTSS_COLORARG0             = 26,
713     WINED3DTSS_ALPHAARG0             = 27,
714     WINED3DTSS_RESULTARG             = 28,
715     WINED3DTSS_CONSTANT              = 32,
716
717     WINED3DTSS_FORCE_DWORD           = 0x7fffffff
718 } WINED3DTEXTURESTAGESTATETYPE;
719
720 #define WINED3DTSS_TCI_PASSTHRU                       0x00000
721 #define WINED3DTSS_TCI_CAMERASPACENORMAL              0x10000
722 #define WINED3DTSS_TCI_CAMERASPACEPOSITION            0x20000
723 #define WINED3DTSS_TCI_CAMERASPACEREFLECTIONVECTOR    0x30000
724 #define WINED3DTSS_TCI_SPHEREMAP                      0x40000
725
726 #define WINED3D_HIGHEST_TEXTURE_STATE WINED3DTSS_CONSTANT
727
728 typedef enum _WINED3DTEXTURETRANSFORMFLAGS {
729     WINED3DTTFF_DISABLE         =   0,
730     WINED3DTTFF_COUNT1          =   1,
731     WINED3DTTFF_COUNT2          =   2,
732     WINED3DTTFF_COUNT3          =   3,
733     WINED3DTTFF_COUNT4          =   4,
734     WINED3DTTFF_PROJECTED       = 256,
735
736     WINED3DTTFF_FORCE_DWORD     = 0x7fffffff
737 } WINED3DTEXTURETRANSFORMFLAGS;
738
739 typedef enum _WINED3DTEXTUREOP {
740     WINED3DTOP_DISABLE                   =  1,
741     WINED3DTOP_SELECTARG1                =  2,
742     WINED3DTOP_SELECTARG2                =  3,
743     WINED3DTOP_MODULATE                  =  4,
744     WINED3DTOP_MODULATE2X                =  5,
745     WINED3DTOP_MODULATE4X                =  6,
746     WINED3DTOP_ADD                       =  7,
747     WINED3DTOP_ADDSIGNED                 =  8,
748     WINED3DTOP_ADDSIGNED2X               =  9,
749     WINED3DTOP_SUBTRACT                  = 10,
750     WINED3DTOP_ADDSMOOTH                 = 11,
751     WINED3DTOP_BLENDDIFFUSEALPHA         = 12,
752     WINED3DTOP_BLENDTEXTUREALPHA         = 13,
753     WINED3DTOP_BLENDFACTORALPHA          = 14,
754     WINED3DTOP_BLENDTEXTUREALPHAPM       = 15,
755     WINED3DTOP_BLENDCURRENTALPHA         = 16,
756     WINED3DTOP_PREMODULATE               = 17,
757     WINED3DTOP_MODULATEALPHA_ADDCOLOR    = 18,
758     WINED3DTOP_MODULATECOLOR_ADDALPHA    = 19,
759     WINED3DTOP_MODULATEINVALPHA_ADDCOLOR = 20,
760     WINED3DTOP_MODULATEINVCOLOR_ADDALPHA = 21,
761     WINED3DTOP_BUMPENVMAP                = 22,
762     WINED3DTOP_BUMPENVMAPLUMINANCE       = 23,
763     WINED3DTOP_DOTPRODUCT3               = 24,
764     WINED3DTOP_MULTIPLYADD               = 25,
765     WINED3DTOP_LERP                      = 26,
766
767     WINED3DTOP_FORCE_DWORD               = 0x7fffffff,
768 } WINED3DTEXTUREOP;
769
770 #define WINED3DTA_SELECTMASK        0x0000000f
771 #define WINED3DTA_DIFFUSE           0x00000000
772 #define WINED3DTA_CURRENT           0x00000001
773 #define WINED3DTA_TEXTURE           0x00000002
774 #define WINED3DTA_TFACTOR           0x00000003
775 #define WINED3DTA_SPECULAR          0x00000004
776 #define WINED3DTA_TEMP              0x00000005
777 #define WINED3DTA_CONSTANT          0x00000006
778 #define WINED3DTA_COMPLEMENT        0x00000010
779 #define WINED3DTA_ALPHAREPLICATE    0x00000020
780
781 typedef enum _WINED3DTEXTUREADDRESS {
782     WINED3DTADDRESS_WRAP            = 1,
783     WINED3DTADDRESS_MIRROR          = 2,
784     WINED3DTADDRESS_CLAMP           = 3,
785     WINED3DTADDRESS_BORDER          = 4,
786     WINED3DTADDRESS_MIRRORONCE      = 5,
787
788     WINED3DTADDRESS_FORCE_DWORD     = 0x7fffffff
789 } WINED3DTEXTUREADDRESS;
790
791 typedef enum _WINED3DTRANSFORMSTATETYPE {
792     WINED3DTS_VIEW            =  2,
793     WINED3DTS_PROJECTION      =  3,
794     WINED3DTS_TEXTURE0        = 16,
795     WINED3DTS_TEXTURE1        = 17,
796     WINED3DTS_TEXTURE2        = 18,
797     WINED3DTS_TEXTURE3        = 19,
798     WINED3DTS_TEXTURE4        = 20,
799     WINED3DTS_TEXTURE5        = 21,
800     WINED3DTS_TEXTURE6        = 22,
801     WINED3DTS_TEXTURE7        = 23,
802
803     WINED3DTS_FORCE_DWORD     = 0x7fffffff
804 } WINED3DTRANSFORMSTATETYPE;
805
806 #define WINED3DTS_WORLD  WINED3DTS_WORLDMATRIX(0)
807 #define WINED3DTS_WORLD1 WINED3DTS_WORLDMATRIX(1)
808 #define WINED3DTS_WORLD2 WINED3DTS_WORLDMATRIX(2)
809 #define WINED3DTS_WORLD3 WINED3DTS_WORLDMATRIX(3)
810 #define WINED3DTS_WORLDMATRIX(index) (WINED3DTRANSFORMSTATETYPE)(index + 256)
811
812 typedef enum _WINED3DBASISTYPE {
813    WINED3DBASIS_BEZIER        = 0,
814    WINED3DBASIS_BSPLINE       = 1,
815    WINED3DBASIS_INTERPOLATE   = 2,
816
817    WINED3DBASIS_FORCE_DWORD   = 0x7fffffff
818 } WINED3DBASISTYPE;
819
820 typedef enum _WINED3DCUBEMAP_FACES {
821     WINED3DCUBEMAP_FACE_POSITIVE_X     = 0,
822     WINED3DCUBEMAP_FACE_NEGATIVE_X     = 1,
823     WINED3DCUBEMAP_FACE_POSITIVE_Y     = 2,
824     WINED3DCUBEMAP_FACE_NEGATIVE_Y     = 3,
825     WINED3DCUBEMAP_FACE_POSITIVE_Z     = 4,
826     WINED3DCUBEMAP_FACE_NEGATIVE_Z     = 5,
827
828     WINED3DCUBEMAP_FACE_FORCE_DWORD    = 0xffffffff
829 } WINED3DCUBEMAP_FACES;
830
831 typedef enum _WINED3DTEXTUREFILTERTYPE {
832     WINED3DTEXF_NONE            = 0,
833     WINED3DTEXF_POINT           = 1,
834     WINED3DTEXF_LINEAR          = 2,
835     WINED3DTEXF_ANISOTROPIC     = 3,
836     WINED3DTEXF_FLATCUBIC       = 4,
837     WINED3DTEXF_GAUSSIANCUBIC   = 5,
838     WINED3DTEXF_PYRAMIDALQUAD   = 6,
839     WINED3DTEXF_GAUSSIANQUAD    = 7,
840     WINED3DTEXF_FORCE_DWORD     = 0x7fffffff
841 } WINED3DTEXTUREFILTERTYPE;
842
843 typedef struct _WINEDD3DRECTPATCH_INFO {
844     UINT                StartVertexOffsetWidth;
845     UINT                StartVertexOffsetHeight;
846     UINT                Width;
847     UINT                Height;
848     UINT                Stride;
849     WINED3DBASISTYPE    Basis;
850     WINED3DDEGREETYPE   Degree;
851 } WINED3DRECTPATCH_INFO;
852
853 typedef struct _WINED3DTRIPATCH_INFO {
854     UINT                StartVertexOffset;
855     UINT                NumVertices;
856     WINED3DBASISTYPE    Basis;
857     WINED3DDEGREETYPE   Degree;
858 } WINED3DTRIPATCH_INFO;
859
860
861 typedef struct _WINED3DADAPTER_IDENTIFIER {
862     char           *Driver;
863     char           *Description;
864     char           *DeviceName;
865     LARGE_INTEGER  *DriverVersion; 
866     DWORD          *VendorId;
867     DWORD          *DeviceId;
868     DWORD          *SubSysId;
869     DWORD          *Revision;
870     GUID           *DeviceIdentifier;
871     DWORD          *WHQLLevel;
872 } WINED3DADAPTER_IDENTIFIER;
873
874 typedef struct _WINED3DPRESENT_PARAMETERS {
875     UINT                    BackBufferWidth;
876     UINT                    BackBufferHeight;
877     WINED3DFORMAT           BackBufferFormat;
878     UINT                    BackBufferCount;
879     WINED3DMULTISAMPLE_TYPE MultiSampleType;
880     DWORD                   MultiSampleQuality;
881     WINED3DSWAPEFFECT       SwapEffect;
882     HWND                    hDeviceWindow;
883     BOOL                    Windowed;
884     BOOL                    EnableAutoDepthStencil;
885     WINED3DFORMAT           AutoDepthStencilFormat;
886     DWORD                   Flags;
887     UINT                    FullScreen_RefreshRateInHz;
888     UINT                    PresentationInterval;
889 } WINED3DPRESENT_PARAMETERS;
890
891 typedef enum _WINED3DRESOURCETYPE {
892     WINED3DRTYPE_SURFACE                =  1,
893     WINED3DRTYPE_VOLUME                 =  2,
894     WINED3DRTYPE_TEXTURE                =  3,
895     WINED3DRTYPE_VOLUMETEXTURE          =  4,
896     WINED3DRTYPE_CUBETEXTURE            =  5,
897     WINED3DRTYPE_VERTEXBUFFER           =  6,
898     WINED3DRTYPE_INDEXBUFFER            =  7,
899
900     WINED3DRTYPE_FORCE_DWORD            = 0x7fffffff
901 } WINED3DRESOURCETYPE;
902
903 #define WINED3DRTYPECOUNT (WINED3DRTYPE_INDEXBUFFER+1)
904
905 typedef enum _WINED3DPOOL {
906     WINED3DPOOL_DEFAULT                 = 0,
907     WINED3DPOOL_MANAGED                 = 1,
908     WINED3DPOOL_SYSTEMMEM               = 2,
909     WINED3DPOOL_SCRATCH                 = 3,
910
911     WINED3DPOOL_FORCE_DWORD             = 0x7fffffff
912 } WINED3DPOOL;
913
914 typedef struct _WINED3DSURFACE_DESC
915 {
916     WINED3DFORMAT           *Format;
917     WINED3DRESOURCETYPE     *Type;
918     DWORD                   *Usage;
919     WINED3DPOOL             *Pool;
920     UINT                    *Size;
921
922     WINED3DMULTISAMPLE_TYPE *MultiSampleType;
923     DWORD                   *MultiSampleQuality;
924     UINT                    *Width;
925     UINT                    *Height;
926 } WINED3DSURFACE_DESC;
927
928 typedef struct _WINED3DVOLUME_DESC
929 {
930     WINED3DFORMAT       *Format;
931     WINED3DRESOURCETYPE *Type;
932     DWORD               *Usage;
933     WINED3DPOOL         *Pool;
934     UINT                *Size;
935
936     UINT                *Width;
937     UINT                *Height;
938     UINT                *Depth;
939 } WINED3DVOLUME_DESC;
940
941 typedef struct _WINED3DCLIPSTATUS {
942    DWORD ClipUnion;
943    DWORD ClipIntersection;
944 } WINED3DCLIPSTATUS;
945
946
947 typedef struct _WINED3DVERTEXELEMENT {
948   WORD    Stream;
949   WORD    Offset;
950   BYTE    Type;
951   BYTE    Method;
952   BYTE    Usage;
953   BYTE    UsageIndex;
954   int     Reg; /* DirectX 8 */
955 } WINED3DVERTEXELEMENT, *LPWINED3DVERTEXELEMENT;
956
957
958 typedef enum _WINED3DQUERYTYPE {
959     WINED3DQUERYTYPE_VCACHE             = 4,
960     WINED3DQUERYTYPE_RESOURCEMANAGER    = 5,
961     WINED3DQUERYTYPE_VERTEXSTATS        = 6,
962     WINED3DQUERYTYPE_EVENT              = 8,
963     WINED3DQUERYTYPE_OCCLUSION          = 9,
964     WINED3DQUERYTYPE_TIMESTAMP          = 10,
965     WINED3DQUERYTYPE_TIMESTAMPDISJOINT  = 11,
966     WINED3DQUERYTYPE_TIMESTAMPFREQ      = 12,
967     WINED3DQUERYTYPE_PIPELINETIMINGS    = 13,
968     WINED3DQUERYTYPE_INTERFACETIMINGS   = 14,
969     WINED3DQUERYTYPE_VERTEXTIMINGS      = 15,
970     WINED3DQUERYTYPE_PIXELTIMINGS       = 16,
971     WINED3DQUERYTYPE_BANDWIDTHTIMINGS   = 17,
972     WINED3DQUERYTYPE_CACHEUTILIZATION   = 18
973 } WINED3DQUERYTYPE;
974
975 #define WINED3DISSUE_BEGIN   (1 << 1)
976 #define WINED3DISSUE_END     (1 << 0)
977 #define WINED3DGETDATA_FLUSH (1 << 0)
978
979 typedef struct _WINED3DDEVICE_CREATION_PARAMETERS {
980     UINT           AdapterOrdinal;
981     WINED3DDEVTYPE DeviceType;
982     HWND           hFocusWindow;
983     DWORD          BehaviorFlags;
984 } WINED3DDEVICE_CREATION_PARAMETERS;
985
986 typedef struct _WINED3DDEVINFO_BANDWIDTHTIMINGS {
987     float         MaxBandwidthUtilized;
988     float         FrontEndUploadMemoryUtilizedPercent;
989     float         VertexRateUtilizedPercent;
990     float         TriangleSetupRateUtilizedPercent;
991     float         FillRateUtilizedPercent;
992 } WINED3DDEVINFO_BANDWIDTHTIMINGS;
993
994 typedef struct _WINED3DDEVINFO_CACHEUTILIZATION {
995     float         TextureCacheHitRate;
996     float         PostTransformVertexCacheHitRate;
997 } WINED3DDEVINFO_CACHEUTILIZATION;
998
999 typedef struct _WINED3DDEVINFO_INTERFACETIMINGS {
1000     float         WaitingForGPUToUseApplicationResourceTimePercent;
1001     float         WaitingForGPUToAcceptMoreCommandsTimePercent;
1002     float         WaitingForGPUToStayWithinLatencyTimePercent;
1003     float         WaitingForGPUExclusiveResourceTimePercent;
1004     float         WaitingForGPUOtherTimePercent;
1005 } WINED3DDEVINFO_INTERFACETIMINGS;
1006
1007 typedef struct _WINED3DDEVINFO_PIPELINETIMINGS {
1008     float         VertexProcessingTimePercent;
1009     float         PixelProcessingTimePercent;
1010     float         OtherGPUProcessingTimePercent;
1011     float         GPUIdleTimePercent;
1012 } WINED3DDEVINFO_PIPELINETIMINGS;
1013
1014 typedef struct _WINED3DDEVINFO_STAGETIMINGS {
1015     float         MemoryProcessingPercent;
1016     float         ComputationProcessingPercent;
1017 } WINED3DDEVINFO_STAGETIMINGS;
1018
1019 typedef struct _WINED3DRASTER_STATUS {
1020     BOOL            InVBlank;
1021     UINT            ScanLine;
1022 } WINED3DRASTER_STATUS;
1023
1024
1025 typedef struct WINED3DRESOURCESTATS {
1026     BOOL                bThrashing;
1027     DWORD               ApproxBytesDownloaded;
1028     DWORD               NumEvicts;
1029     DWORD               NumVidCreates;
1030     DWORD               LastPri;
1031     DWORD               NumUsed;
1032     DWORD               NumUsedInVidMem;
1033     DWORD               WorkingSet;
1034     DWORD               WorkingSetBytes;
1035     DWORD               TotalManaged;
1036     DWORD               TotalBytes;
1037 } WINED3DRESOURCESTATS;
1038
1039 typedef struct _WINED3DDEVINFO_RESOURCEMANAGER {
1040     WINED3DRESOURCESTATS stats[WINED3DRTYPECOUNT];
1041 } WINED3DDEVINFO_RESOURCEMANAGER;
1042
1043 typedef struct _WINED3DDEVINFO_VERTEXSTATS {
1044     DWORD NumRenderedTriangles;
1045     DWORD NumExtraClippingTriangles;
1046 } WINED3DDEVINFO_VERTEXSTATS;
1047
1048 typedef struct _WINED3DLOCKED_RECT {
1049     INT                 Pitch;
1050     void*               pBits;
1051 } WINED3DLOCKED_RECT;
1052
1053 typedef struct _WINED3DLOCKED_BOX {
1054     INT                 RowPitch;
1055     INT                 SlicePitch;
1056     void*               pBits;
1057 } WINED3DLOCKED_BOX;
1058
1059
1060 typedef struct _WINED3DBOX {
1061     UINT                Left;
1062     UINT                Top;
1063     UINT                Right;
1064     UINT                Bottom;
1065     UINT                Front;
1066     UINT                Back;
1067 } WINED3DBOX;
1068
1069 /*Vertex cache optimization hints.*/
1070 typedef struct WINED3DDEVINFO_VCACHE {
1071     /*Must be a 4 char code FOURCC (e.g. CACH)*/
1072     DWORD         Pattern; 
1073     /*0 to get the longest  strips, 1 vertex cache*/
1074     DWORD         OptMethod; 
1075      /*Cache size to use (only valid if OptMethod==1) */
1076     DWORD         CacheSize;
1077     /*internal for deciding when to restart strips, non user modifyable (only valid if OptMethod==1)*/
1078     DWORD         MagicNumber; 
1079 } WINED3DDEVINFO_VCACHE;
1080
1081 typedef struct _WINED3DVERTEXBUFFER_DESC {
1082     WINED3DFORMAT           Format;
1083     WINED3DRESOURCETYPE     Type;
1084     DWORD                   Usage;
1085     WINED3DPOOL             Pool;
1086     UINT                    Size;
1087     DWORD                   FVF;
1088 } WINED3DVERTEXBUFFER_DESC;
1089
1090 typedef struct _WINED3DINDEXBUFFER_DESC {
1091     WINED3DFORMAT           Format;
1092     WINED3DRESOURCETYPE     Type;
1093     DWORD                   Usage;
1094     WINED3DPOOL             Pool;
1095     UINT                    Size;
1096 } WINED3DINDEXBUFFER_DESC;
1097
1098 /*
1099  * The wined3dcaps structure
1100  */
1101
1102 typedef struct _WINED3DVSHADERCAPS2_0 {
1103   DWORD  Caps;
1104   INT    DynamicFlowControlDepth;
1105   INT    NumTemps;
1106   INT    StaticFlowControlDepth;
1107 } WINED3DVSHADERCAPS2_0;
1108
1109 typedef struct _WINED3DPSHADERCAPS2_0 {
1110   DWORD  Caps;
1111   INT    DynamicFlowControlDepth;
1112   INT    NumTemps;
1113   INT    StaticFlowControlDepth;
1114   INT    NumInstructionSlots;
1115 } WINED3DPSHADERCAPS2_0;
1116
1117 typedef struct _WINEDDCAPS {
1118     DWORD Caps;
1119     DWORD Caps2;
1120     DWORD CKeyCaps;
1121     DWORD FXCaps;
1122     DWORD FXAlphaCaps;
1123     DWORD PalCaps;
1124     DWORD SVCaps;
1125     DWORD SVBCaps;
1126     DWORD SVBCKeyCaps;
1127     DWORD SVBFXCaps;
1128     DWORD VSBCaps;
1129     DWORD VSBCKeyCaps;
1130     DWORD VSBFXCaps;
1131     DWORD SSBCaps;
1132     DWORD SSBCKeyCaps;
1133     DWORD SSBFXCaps;
1134     DWORD ddsCaps;
1135     DWORD StrideAlign;
1136 } WINEDDCAPS;
1137
1138 typedef struct _WINED3DCAPS {
1139   WINED3DDEVTYPE      DeviceType;
1140   UINT                AdapterOrdinal;
1141
1142   DWORD               Caps;
1143   DWORD               Caps2;
1144   DWORD               Caps3;
1145   DWORD               PresentationIntervals;
1146
1147   DWORD               CursorCaps;
1148
1149   DWORD               DevCaps;
1150
1151   DWORD               PrimitiveMiscCaps;
1152   DWORD               RasterCaps;
1153   DWORD               ZCmpCaps;
1154   DWORD               SrcBlendCaps;
1155   DWORD               DestBlendCaps;
1156   DWORD               AlphaCmpCaps;
1157   DWORD               ShadeCaps;
1158   DWORD               TextureCaps;
1159   DWORD               TextureFilterCaps;
1160   DWORD               CubeTextureFilterCaps;
1161   DWORD               VolumeTextureFilterCaps;
1162   DWORD               TextureAddressCaps;
1163   DWORD               VolumeTextureAddressCaps;
1164
1165   DWORD               LineCaps;
1166
1167   DWORD               MaxTextureWidth;
1168   DWORD               MaxTextureHeight;
1169   DWORD               MaxVolumeExtent;
1170
1171   DWORD               MaxTextureRepeat;
1172   DWORD               MaxTextureAspectRatio;
1173   DWORD               MaxAnisotropy;
1174   float               MaxVertexW;
1175
1176   float               GuardBandLeft;
1177   float               GuardBandTop;
1178   float               GuardBandRight;
1179   float               GuardBandBottom;
1180
1181   float               ExtentsAdjust;
1182   DWORD               StencilCaps;
1183
1184   DWORD               FVFCaps;
1185   DWORD               TextureOpCaps;
1186   DWORD               MaxTextureBlendStages;
1187   DWORD               MaxSimultaneousTextures;
1188
1189   DWORD               VertexProcessingCaps;
1190   DWORD               MaxActiveLights;
1191   DWORD               MaxUserClipPlanes;
1192   DWORD               MaxVertexBlendMatrices;
1193   DWORD               MaxVertexBlendMatrixIndex;
1194
1195   float               MaxPointSize;
1196
1197   DWORD               MaxPrimitiveCount;
1198   DWORD               MaxVertexIndex;
1199   DWORD               MaxStreams;
1200   DWORD               MaxStreamStride;
1201
1202   DWORD               VertexShaderVersion;
1203   DWORD               MaxVertexShaderConst;
1204
1205   DWORD               PixelShaderVersion;
1206   float               PixelShader1xMaxValue;
1207
1208   /* DX 9 */
1209   DWORD               DevCaps2;
1210
1211   float               MaxNpatchTessellationLevel;
1212   DWORD               Reserved5; /*undocumented*/
1213
1214   UINT                MasterAdapterOrdinal;
1215   UINT                AdapterOrdinalInGroup;
1216   UINT                NumberOfAdaptersInGroup;
1217   DWORD               DeclTypes;
1218   DWORD               NumSimultaneousRTs;
1219   DWORD               StretchRectFilterCaps;
1220   WINED3DVSHADERCAPS2_0   VS20Caps;
1221   WINED3DPSHADERCAPS2_0   PS20Caps;
1222   DWORD               VertexTextureFilterCaps;
1223   DWORD               MaxVShaderInstructionsExecuted;
1224   DWORD               MaxPShaderInstructionsExecuted;
1225   DWORD               MaxVertexShader30InstructionSlots;
1226   DWORD               MaxPixelShader30InstructionSlots;
1227   DWORD               Reserved2;/* Not in the microsoft headers but documented */
1228   DWORD               Reserved3;
1229
1230   WINEDDCAPS          DirectDrawCaps;
1231 } WINED3DCAPS;
1232
1233 typedef enum _WINED3DSTATEBLOCKTYPE {
1234     WINED3DSBT_INIT          = 0,
1235     WINED3DSBT_ALL           = 1,
1236     WINED3DSBT_PIXELSTATE    = 2,
1237     WINED3DSBT_VERTEXSTATE   = 3,
1238     WINED3DSBT_RECORDED      = 4,       /* WineD3D private */
1239
1240     WINED3DSBT_FORCE_DWORD   = 0xffffffff
1241 } WINED3DSTATEBLOCKTYPE;
1242
1243 typedef struct glDescriptor {
1244     UINT          textureName;
1245     int           level;
1246     int           target;
1247     int/*GLenum*/ glFormat;
1248     int/*GLenum*/ glFormatInternal;
1249     int/*GLenum*/ glType;
1250 } glDescriptor;
1251
1252 #define WINED3DDP_MAXTEXCOORD 8
1253
1254 typedef enum _WINED3DDECLMETHOD {
1255     WINED3DDECLMETHOD_DEFAULT          = 0,
1256     WINED3DDECLMETHOD_PARTIALU         = 1,
1257     WINED3DDECLMETHOD_PARTIALV         = 2,
1258     WINED3DDECLMETHOD_CROSSUV          = 3,
1259     WINED3DDECLMETHOD_UV               = 4,
1260     WINED3DDECLMETHOD_LOOKUP           = 5,
1261     WINED3DDECLMETHOD_LOOKUPPRESAMPLED = 6
1262 } WINED3DDECLMETHOD;
1263
1264 typedef enum _WINED3DDECLTYPE {
1265   WINED3DDECLTYPE_FLOAT1    =  0,
1266   WINED3DDECLTYPE_FLOAT2    =  1,
1267   WINED3DDECLTYPE_FLOAT3    =  2,
1268   WINED3DDECLTYPE_FLOAT4    =  3,
1269   WINED3DDECLTYPE_D3DCOLOR  =  4,
1270   WINED3DDECLTYPE_UBYTE4    =  5,
1271   WINED3DDECLTYPE_SHORT2    =  6,
1272   WINED3DDECLTYPE_SHORT4    =  7,
1273   /* VS 2.0 */
1274   WINED3DDECLTYPE_UBYTE4N   =  8,
1275   WINED3DDECLTYPE_SHORT2N   =  9,
1276   WINED3DDECLTYPE_SHORT4N   = 10,
1277   WINED3DDECLTYPE_USHORT2N  = 11,
1278   WINED3DDECLTYPE_USHORT4N  = 12,
1279   WINED3DDECLTYPE_UDEC3     = 13,
1280   WINED3DDECLTYPE_DEC3N     = 14,
1281   WINED3DDECLTYPE_FLOAT16_2 = 15,
1282   WINED3DDECLTYPE_FLOAT16_4 = 16,
1283   WINED3DDECLTYPE_UNUSED    = 17,
1284 } WINED3DDECLTYPE;
1285
1286 #define WINED3DDECL_END() {0xFF,0,WINED3DDECLTYPE_UNUSED,0,0,0,-1}
1287
1288 typedef struct WineDirect3DStridedData {
1289     BYTE     *lpData;        /* Pointer to start of data                */
1290     DWORD     dwStride;      /* Stride between occurrences of this data */
1291     DWORD     dwType;        /* Type (as in D3DVSDT_TYPE)               */
1292     int       VBO;           /* Vertex buffer object this data is in    */
1293     UINT      streamNo;      /* D3D stream number                       */
1294 } WineDirect3DStridedData;
1295
1296 typedef struct WineDirect3DVertexStridedData {
1297     /* IMPORTANT:
1298      *
1299      * This structure can be accessed in two ways: Named access, and array
1300      * access. Please note that named access is only valid with the fixed
1301      * function vertex pipeline, and the arrays are only valid with the
1302      * programmable vertex pipeline(vertex shaders)
1303      */
1304     union {
1305         struct {
1306
1307              /* Do not add or reorder fields here,
1308               * so this can be indexed as an array */
1309              WineDirect3DStridedData  position;
1310              WineDirect3DStridedData  blendWeights;
1311              WineDirect3DStridedData  blendMatrixIndices;
1312              WineDirect3DStridedData  normal;
1313              WineDirect3DStridedData  pSize;
1314              WineDirect3DStridedData  diffuse;
1315              WineDirect3DStridedData  specular;
1316              WineDirect3DStridedData  texCoords[WINED3DDP_MAXTEXCOORD];
1317              WineDirect3DStridedData  position2; /* tween data */
1318              WineDirect3DStridedData  normal2;   /* tween data */
1319              WineDirect3DStridedData  tangent;
1320              WineDirect3DStridedData  binormal;
1321              WineDirect3DStridedData  tessFactor;
1322              WineDirect3DStridedData  fog;
1323              WineDirect3DStridedData  depth;
1324              WineDirect3DStridedData  sample;
1325
1326              /* Add fields here */
1327              BOOL position_transformed;
1328
1329         } s;
1330         WineDirect3DStridedData input[16];  /* Indexed by constants in D3DVSDE_REGISTER */
1331     } u;
1332 } WineDirect3DVertexStridedData;
1333
1334 typedef enum {
1335     WINED3DDECLUSAGE_POSITION     = 0,
1336     WINED3DDECLUSAGE_BLENDWEIGHT  = 1,
1337     WINED3DDECLUSAGE_BLENDINDICES = 2,
1338     WINED3DDECLUSAGE_NORMAL       = 3,
1339     WINED3DDECLUSAGE_PSIZE        = 4,
1340     WINED3DDECLUSAGE_TEXCOORD     = 5,
1341     WINED3DDECLUSAGE_TANGENT      = 6,
1342     WINED3DDECLUSAGE_BINORMAL     = 7,
1343     WINED3DDECLUSAGE_TESSFACTOR   = 8,
1344     WINED3DDECLUSAGE_POSITIONT    = 9,
1345     WINED3DDECLUSAGE_COLOR        = 10,
1346     WINED3DDECLUSAGE_FOG          = 11,
1347     WINED3DDECLUSAGE_DEPTH        = 12,
1348     WINED3DDECLUSAGE_SAMPLE       = 13
1349 } WINED3DDECLUSAGE;
1350
1351 #define WINED3DUSAGE_RENDERTARGET                     0x00000001L
1352 #define WINED3DUSAGE_DEPTHSTENCIL                     0x00000002L
1353 #define WINED3DUSAGE_WRITEONLY                        0x00000008L
1354 #define WINED3DUSAGE_SOFTWAREPROCESSING               0x00000010L
1355 #define WINED3DUSAGE_DONOTCLIP                        0x00000020L
1356 #define WINED3DUSAGE_POINTS                           0x00000040L
1357 #define WINED3DUSAGE_RTPATCHES                        0x00000080L
1358 #define WINED3DUSAGE_NPATCHES                         0x00000100L
1359 #define WINED3DUSAGE_DYNAMIC                          0x00000200L
1360 #define WINED3DUSAGE_AUTOGENMIPMAP                    0x00000400L 
1361 #define WINED3DUSAGE_DMAP                             0x00004000L
1362 #define WINED3DUSAGE_MASK                             0x00004FFFL
1363 #define WINED3DUSAGE_OVERLAY                          0x80000000L
1364
1365 #define WINED3DUSAGE_QUERY_LEGACYBUMPMAP            0x00008000L
1366 #define WINED3DUSAGE_QUERY_FILTER                   0x00020000L
1367 #define WINED3DUSAGE_QUERY_POSTPIXELSHADER_BLENDING 0x00080000L
1368 #define WINED3DUSAGE_QUERY_SRGBREAD                 0x00010000L
1369 #define WINED3DUSAGE_QUERY_SRGBWRITE                0x00040000L
1370 #define WINED3DUSAGE_QUERY_VERTEXTEXTURE            0x00100000L
1371 #define WINED3DUSAGE_QUERY_WRAPANDMIP               0x00200000L
1372 #define WINED3DUSAGE_QUERY_MASK                     0x003F8000L
1373
1374 typedef enum _WINED3DSURFTYPE {
1375     SURFACE_UNKNOWN    = 0,   /* Default / Unknown surface type */
1376     SURFACE_OPENGL,           /* OpenGL surface: Renders using libGL, needed for 3D */
1377     SURFACE_GDI,              /* User surface. No 3D, DirectDraw rendering with GDI */
1378 } WINED3DSURFTYPE;
1379
1380 #define WINED3DCAPS2_NO2DDURING3DSCENE                 0x00000002L
1381 #define WINED3DCAPS2_FULLSCREENGAMMA                   0x00020000L
1382 #define WINED3DCAPS2_CANRENDERWINDOWED                 0x00080000L
1383 #define WINED3DCAPS2_CANCALIBRATEGAMMA                 0x00100000L
1384 #define WINED3DCAPS2_RESERVED                          0x02000000L
1385 #define WINED3DCAPS2_CANMANAGERESOURCE                 0x10000000L
1386 #define WINED3DCAPS2_DYNAMICTEXTURES                   0x20000000L
1387 #define WINED3DCAPS2_CANAUTOGENMIPMAP                  0x40000000L
1388
1389 #define WINED3DPRASTERCAPS_DITHER                     0x00000001L
1390 #define WINED3DPRASTERCAPS_ROP2                       0x00000002L
1391 #define WINED3DPRASTERCAPS_XOR                        0x00000004L
1392 #define WINED3DPRASTERCAPS_PAT                        0x00000008L
1393 #define WINED3DPRASTERCAPS_ZTEST                      0x00000010L
1394 #define WINED3DPRASTERCAPS_SUBPIXEL                   0x00000020L
1395 #define WINED3DPRASTERCAPS_SUBPIXELX                  0x00000040L
1396 #define WINED3DPRASTERCAPS_FOGVERTEX                  0x00000080L
1397 #define WINED3DPRASTERCAPS_FOGTABLE                   0x00000100L
1398 #define WINED3DPRASTERCAPS_STIPPLE                    0x00000200L
1399 #define WINED3DPRASTERCAPS_ANTIALIASSORTDEPENDENT     0x00000400L
1400 #define WINED3DPRASTERCAPS_ANTIALIASSORTINDEPENDENT   0x00000800L
1401 #define WINED3DPRASTERCAPS_ANTIALIASEDGES             0x00001000L
1402 #define WINED3DPRASTERCAPS_MIPMAPLODBIAS              0x00002000L
1403 #define WINED3DPRASTERCAPS_ZBIAS                      0x00004000L
1404 #define WINED3DPRASTERCAPS_ZBUFFERLESSHSR             0x00008000L
1405 #define WINED3DPRASTERCAPS_FOGRANGE                   0x00010000L
1406 #define WINED3DPRASTERCAPS_ANISOTROPY                 0x00020000L
1407 #define WINED3DPRASTERCAPS_WBUFFER                    0x00040000L
1408 #define WINED3DPRASTERCAPS_TRANSLUCENTSORTINDEPENDENT 0x00080000L
1409 #define WINED3DPRASTERCAPS_WFOG                       0x00100000L
1410 #define WINED3DPRASTERCAPS_ZFOG                       0x00200000L
1411 #define WINED3DPRASTERCAPS_COLORPERSPECTIVE           0x00400000L
1412 #define WINED3DPRASTERCAPS_SCISSORTEST                0x01000000L
1413 #define WINED3DPRASTERCAPS_SLOPESCALEDEPTHBIAS        0x02000000L
1414 #define WINED3DPRASTERCAPS_DEPTHBIAS                  0x04000000L 
1415 #define WINED3DPRASTERCAPS_MULTISAMPLE_TOGGLE         0x08000000L
1416
1417 #define WINED3DPSHADECAPS_COLORFLATMONO               0x000001
1418 #define WINED3DPSHADECAPS_COLORFLATRGB                0x000002
1419 #define WINED3DPSHADECAPS_COLORGOURAUDMONO            0x000004
1420 #define WINED3DPSHADECAPS_COLORGOURAUDRGB             0x000008
1421 #define WINED3DPSHADECAPS_COLORPHONGMONO              0x000010
1422 #define WINED3DPSHADECAPS_COLORPHONGRGB               0x000020
1423 #define WINED3DPSHADECAPS_SPECULARFLATMONO            0x000040
1424 #define WINED3DPSHADECAPS_SPECULARFLATRGB             0x000080
1425 #define WINED3DPSHADECAPS_SPECULARGOURAUDMONO         0x000100
1426 #define WINED3DPSHADECAPS_SPECULARGOURAUDRGB          0x000200
1427 #define WINED3DPSHADECAPS_SPECULARPHONGMONO           0x000400
1428 #define WINED3DPSHADECAPS_SPECULARPHONGRGB            0x000800
1429 #define WINED3DPSHADECAPS_ALPHAFLATBLEND              0x001000
1430 #define WINED3DPSHADECAPS_ALPHAFLATSTIPPLED           0x002000
1431 #define WINED3DPSHADECAPS_ALPHAGOURAUDBLEND           0x004000
1432 #define WINED3DPSHADECAPS_ALPHAGOURAUDSTIPPLED        0x008000
1433 #define WINED3DPSHADECAPS_ALPHAPHONGBLEND             0x010000
1434 #define WINED3DPSHADECAPS_ALPHAPHONGSTIPPLED          0x020000
1435 #define WINED3DPSHADECAPS_FOGFLAT                     0x040000
1436 #define WINED3DPSHADECAPS_FOGGOURAUD                  0x080000
1437 #define WINED3DPSHADECAPS_FOGPHONG                    0x100000
1438
1439 #define WINED3DPTEXTURECAPS_PERSPECTIVE              0x00000001L
1440 #define WINED3DPTEXTURECAPS_POW2                     0x00000002L
1441 #define WINED3DPTEXTURECAPS_ALPHA                    0x00000004L
1442 #define WINED3DPTEXTURECAPS_TRANSPARENCY             0x00000008L
1443 #define WINED3DPTEXTURECAPS_BORDER                   0x00000010L
1444 #define WINED3DPTEXTURECAPS_SQUAREONLY               0x00000020L
1445 #define WINED3DPTEXTURECAPS_TEXREPEATNOTSCALEDBYSIZE 0x00000040L
1446 #define WINED3DPTEXTURECAPS_ALPHAPALETTE             0x00000080L
1447 #define WINED3DPTEXTURECAPS_NONPOW2CONDITIONAL       0x00000100L
1448 #define WINED3DPTEXTURECAPS_PROJECTED                0x00000400L
1449 #define WINED3DPTEXTURECAPS_CUBEMAP                  0x00000800L
1450 #define WINED3DPTEXTURECAPS_COLORKEYBLEND            0x00001000L
1451 #define WINED3DPTEXTURECAPS_VOLUMEMAP                0x00002000L
1452 #define WINED3DPTEXTURECAPS_MIPMAP                   0x00004000L
1453 #define WINED3DPTEXTURECAPS_MIPVOLUMEMAP             0x00008000L
1454 #define WINED3DPTEXTURECAPS_MIPCUBEMAP               0x00010000L
1455 #define WINED3DPTEXTURECAPS_CUBEMAP_POW2             0x00020000L
1456 #define WINED3DPTEXTURECAPS_VOLUMEMAP_POW2           0x00040000L
1457 #define WINED3DPTEXTURECAPS_NOPROJECTEDBUMPENV       0x00200000L
1458
1459 #define WINED3DPTFILTERCAPS_NEAREST                  0x00000001
1460 #define WINED3DPTFILTERCAPS_LINEAR                   0x00000002
1461 #define WINED3DPTFILTERCAPS_MIPNEAREST               0x00000004
1462 #define WINED3DPTFILTERCAPS_MIPLINEAR                0x00000008
1463 #define WINED3DPTFILTERCAPS_LINEARMIPNEAREST         0x00000010
1464 #define WINED3DPTFILTERCAPS_LINEARMIPLINEAR          0x00000020
1465 #define WINED3DPTFILTERCAPS_MINFPOINT                0x00000100
1466 #define WINED3DPTFILTERCAPS_MINFLINEAR               0x00000200
1467 #define WINED3DPTFILTERCAPS_MINFANISOTROPIC          0x00000400
1468 #define WINED3DPTFILTERCAPS_MIPFPOINT                0x00010000
1469 #define WINED3DPTFILTERCAPS_MIPFLINEAR               0x00020000
1470 #define WINED3DPTFILTERCAPS_MAGFPOINT                0x01000000
1471 #define WINED3DPTFILTERCAPS_MAGFLINEAR               0x02000000
1472 #define WINED3DPTFILTERCAPS_MAGFANISOTROPIC          0x04000000
1473 #define WINED3DPTFILTERCAPS_MAGFPYRAMIDALQUAD        0x08000000
1474 #define WINED3DPTFILTERCAPS_MAGFGAUSSIANQUAD         0x10000000
1475
1476 #define WINED3DVTXPCAPS_TEXGEN                       0x00000001L
1477 #define WINED3DVTXPCAPS_MATERIALSOURCE7              0x00000002L
1478 #define WINED3DVTXPCAPS_VERTEXFOG                    0x00000004L
1479 #define WINED3DVTXPCAPS_DIRECTIONALLIGHTS            0x00000008L
1480 #define WINED3DVTXPCAPS_POSITIONALLIGHTS             0x00000010L
1481 #define WINED3DVTXPCAPS_LOCALVIEWER                  0x00000020L
1482 #define WINED3DVTXPCAPS_TWEENING                     0x00000040L
1483 #define WINED3DVTXPCAPS_TEXGEN_SPHEREMAP             0x00000100L
1484 #define WINED3DVTXPCAPS_NO_TEXGEN_NONLOCALVIEWER     0x00000200L
1485
1486 #define WINED3DCURSORCAPS_COLOR                      0x000000001
1487 #define WINED3DCURSORCAPS_LOWRES                     0x000000002
1488
1489 #define WINED3DDEVCAPS_FLOATTLVERTEX                 0x000000001
1490 #define WINED3DDEVCAPS_SORTINCREASINGZ               0x000000002
1491 #define WINED3DDEVCAPS_SORTDECREASINGZ               0X000000004
1492 #define WINED3DDEVCAPS_SORTEXACT                     0x000000008
1493 #define WINED3DDEVCAPS_EXECUTESYSTEMMEMORY           0x000000010
1494 #define WINED3DDEVCAPS_EXECUTEVIDEOMEMORY            0x000000020
1495 #define WINED3DDEVCAPS_TLVERTEXSYSTEMMEMORY          0x000000040
1496 #define WINED3DDEVCAPS_TLVERTEXVIDEOMEMORY           0x000000080
1497 #define WINED3DDEVCAPS_TEXTURESYSTEMMEMORY           0x000000100
1498 #define WINED3DDEVCAPS_TEXTUREVIDEOMEMORY            0x000000200
1499 #define WINED3DDEVCAPS_DRAWPRIMTLVERTEX              0x000000400
1500 #define WINED3DDEVCAPS_CANRENDERAFTERFLIP            0x000000800
1501 #define WINED3DDEVCAPS_TEXTURENONLOCALVIDMEM         0x000001000
1502 #define WINED3DDEVCAPS_DRAWPRIMITIVES2               0x000002000
1503 #define WINED3DDEVCAPS_SEPARATETEXTUREMEMORIES       0x000004000
1504 #define WINED3DDEVCAPS_DRAWPRIMITIVES2EX             0x000008000
1505 #define WINED3DDEVCAPS_HWTRANSFORMANDLIGHT           0x000010000
1506 #define WINED3DDEVCAPS_CANBLTSYSTONONLOCAL           0x000020000
1507 #define WINED3DDEVCAPS_HWRASTERIZATION               0x000080000
1508 #define WINED3DDEVCAPS_PUREDEVICE                    0x000100000
1509 #define WINED3DDEVCAPS_QUINTICRTPATCHES              0x000200000
1510 #define WINED3DDEVCAPS_RTPATCHES                     0x000400000
1511 #define WINED3DDEVCAPS_RTPATCHHANDLEZERO             0x000800000
1512 #define WINED3DDEVCAPS_NPATCHES                      0x001000000
1513
1514 #define WINED3DLOCK_READONLY           0x0010
1515 #define WINED3DLOCK_NOSYSLOCK          0x0800
1516 #define WINED3DLOCK_NOOVERWRITE        0x1000
1517 #define WINED3DLOCK_DISCARD            0x2000
1518 #define WINED3DLOCK_DONOTWAIT          0x4000
1519 #define WINED3DLOCK_NO_DIRTY_UPDATE    0x8000
1520
1521 #define WINED3DPRESENT_RATE_DEFAULT                  0x000000000
1522
1523 #define WINED3DPRESENT_INTERVAL_DEFAULT              0x00000000
1524 #define WINED3DPRESENT_INTERVAL_ONE                  0x00000001
1525 #define WINED3DPRESENT_INTERVAL_TWO                  0x00000002
1526 #define WINED3DPRESENT_INTERVAL_THREE                0x00000004
1527 #define WINED3DPRESENT_INTERVAL_FOUR                 0x00000008
1528 #define WINED3DPRESENT_INTERVAL_IMMEDIATE            0x80000000
1529
1530 #define WINED3DMAXUSERCLIPPLANES       32
1531 #define WINED3DCLIPPLANE0              (1 << 0)
1532 #define WINED3DCLIPPLANE1              (1 << 1)
1533 #define WINED3DCLIPPLANE2              (1 << 2)
1534 #define WINED3DCLIPPLANE3              (1 << 3)
1535 #define WINED3DCLIPPLANE4              (1 << 4)
1536 #define WINED3DCLIPPLANE5              (1 << 5)
1537
1538 /* FVF (Flexible Vertex Format) codes */
1539 #define WINED3DFVF_RESERVED0           0x0001
1540 #define WINED3DFVF_POSITION_MASK       0x000E
1541 #define WINED3DFVF_XYZ                 0x0002
1542 #define WINED3DFVF_XYZRHW              0x0004
1543 #define WINED3DFVF_XYZB1               0x0006
1544 #define WINED3DFVF_XYZB2               0x0008
1545 #define WINED3DFVF_XYZB3               0x000a
1546 #define WINED3DFVF_XYZB4               0x000c
1547 #define WINED3DFVF_XYZB5               0x000e
1548 #define WINED3DFVF_XYZW                0x4002
1549 #define WINED3DFVF_NORMAL              0x0010
1550 #define WINED3DFVF_PSIZE               0x0020
1551 #define WINED3DFVF_DIFFUSE             0x0040
1552 #define WINED3DFVF_SPECULAR            0x0080
1553 #define WINED3DFVF_TEXCOUNT_MASK       0x0f00
1554 #define WINED3DFVF_TEXCOUNT_SHIFT           8
1555 #define WINED3DFVF_TEX0                0x0000
1556 #define WINED3DFVF_TEX1                0x0100
1557 #define WINED3DFVF_TEX2                0x0200
1558 #define WINED3DFVF_TEX3                0x0300
1559 #define WINED3DFVF_TEX4                0x0400
1560 #define WINED3DFVF_TEX5                0x0500
1561 #define WINED3DFVF_TEX6                0x0600
1562 #define WINED3DFVF_TEX7                0x0700
1563 #define WINED3DFVF_TEX8                0x0800
1564 #define WINED3DFVF_LASTBETA_UBYTE4     0x1000
1565 #define WINED3DFVF_LASTBETA_D3DCOLOR   0x8000
1566 #define WINED3DFVF_RESERVED2           0x6000
1567
1568 #define WINED3DFVF_TEXTUREFORMAT1 3
1569 #define WINED3DFVF_TEXTUREFORMAT2 0
1570 #define WINED3DFVF_TEXTUREFORMAT3 1
1571 #define WINED3DFVF_TEXTUREFORMAT4 2
1572 #define WINED3DFVF_TEXCOORDSIZE1(CoordIndex) (WINED3DFVF_TEXTUREFORMAT1 << (CoordIndex*2 + 16))
1573 #define WINED3DFVF_TEXCOORDSIZE2(CoordIndex) (WINED3DFVF_TEXTUREFORMAT2)
1574 #define WINED3DFVF_TEXCOORDSIZE3(CoordIndex) (WINED3DFVF_TEXTUREFORMAT3 << (CoordIndex*2 + 16))
1575 #define WINED3DFVF_TEXCOORDSIZE4(CoordIndex) (WINED3DFVF_TEXTUREFORMAT4 << (CoordIndex*2 + 16))
1576
1577 /* Clear flags */
1578 #define WINED3DCLEAR_TARGET   0x00000001
1579 #define WINED3DCLEAR_ZBUFFER  0x00000002
1580 #define WINED3DCLEAR_STENCIL  0x00000004
1581
1582 /* Stream source flags */
1583 #define WINED3DSTREAMSOURCE_INDEXEDDATA  (1 << 30)
1584 #define WINED3DSTREAMSOURCE_INSTANCEDATA (2 << 30)
1585
1586 /* SetPrivateData flags */
1587 #define WINED3DSPD_IUNKNOWN 0x00000001
1588
1589 /* IWineD3D::CreateDevice behaviour flags */
1590 #define WINED3DCREATE_FPU_PRESERVE                  0x00000002
1591 #define WINED3DCREATE_PUREDEVICE                    0x00000010
1592 #define WINED3DCREATE_SOFTWARE_VERTEXPROCESSING     0x00000020
1593 #define WINED3DCREATE_HARDWARE_VERTEXPROCESSING     0x00000040
1594 #define WINED3DCREATE_MIXED_VERTEXPROCESSING        0x00000080
1595 #define WINED3DCREATE_DISABLE_DRIVER_MANAGEMENT     0x00000100
1596 #define WINED3DCREATE_ADAPTERGROUP_DEVICE           0x00000200
1597
1598 /* VTF defines */
1599 #define WINED3DDMAPSAMPLER              0x100
1600 #define WINED3DVERTEXTEXTURESAMPLER0    (WINED3DDMAPSAMPLER + 1)
1601 #define WINED3DVERTEXTEXTURESAMPLER1    (WINED3DDMAPSAMPLER + 2)
1602 #define WINED3DVERTEXTEXTURESAMPLER2    (WINED3DDMAPSAMPLER + 3)
1603 #define WINED3DVERTEXTEXTURESAMPLER3    (WINED3DDMAPSAMPLER + 4)
1604
1605 /* DirectDraw types */
1606
1607 typedef struct _WINEDDCOLORKEY
1608 {
1609     DWORD       dwColorSpaceLowValue;           /* low boundary of color space that is to
1610                                                  * be treated as Color Key, inclusive
1611                                                  */
1612     DWORD       dwColorSpaceHighValue;          /* high boundary of color space that is
1613                                                  * to be treated as Color Key, inclusive
1614                                                  */
1615 } WINEDDCOLORKEY,*LPWINEDDCOLORKEY;
1616
1617 typedef struct _WINEDDBLTFX
1618 {
1619     DWORD       dwSize;                         /* size of structure */
1620     DWORD       dwDDFX;                         /* FX operations */
1621     DWORD       dwROP;                          /* Win32 raster operations */
1622     DWORD       dwDDROP;                        /* Raster operations new for DirectDraw */
1623     DWORD       dwRotationAngle;                /* Rotation angle for blt */
1624     DWORD       dwZBufferOpCode;                /* ZBuffer compares */
1625     DWORD       dwZBufferLow;                   /* Low limit of Z buffer */
1626     DWORD       dwZBufferHigh;                  /* High limit of Z buffer */
1627     DWORD       dwZBufferBaseDest;              /* Destination base value */
1628     DWORD       dwZDestConstBitDepth;           /* Bit depth used to specify Z constant for destination */
1629     union
1630     {
1631         DWORD   dwZDestConst;                   /* Constant to use as Z buffer for dest */
1632         struct IWineD3DSurface *lpDDSZBufferDest;      /* Surface to use as Z buffer for dest */
1633     } DUMMYUNIONNAME1;
1634     DWORD       dwZSrcConstBitDepth;            /* Bit depth used to specify Z constant for source */
1635     union
1636     {
1637         DWORD   dwZSrcConst;                    /* Constant to use as Z buffer for src */
1638         struct IWineD3DSurface *lpDDSZBufferSrc;/* Surface to use as Z buffer for src */
1639     } DUMMYUNIONNAME2;
1640     DWORD       dwAlphaEdgeBlendBitDepth;       /* Bit depth used to specify constant for alpha edge blend */
1641     DWORD       dwAlphaEdgeBlend;               /* Alpha for edge blending */
1642     DWORD       dwReserved;
1643     DWORD       dwAlphaDestConstBitDepth;       /* Bit depth used to specify alpha constant for destination */
1644     union
1645     {
1646         DWORD   dwAlphaDestConst;               /* Constant to use as Alpha Channel */
1647         struct IWineD3DSurface *lpDDSAlphaDest; /* Surface to use as Alpha Channel */
1648     } DUMMYUNIONNAME3;
1649     DWORD       dwAlphaSrcConstBitDepth;        /* Bit depth used to specify alpha constant for source */
1650     union
1651     {
1652         DWORD   dwAlphaSrcConst;                /* Constant to use as Alpha Channel */
1653         struct IWineD3DSurface *lpDDSAlphaSrc;  /* Surface to use as Alpha Channel */
1654     } DUMMYUNIONNAME4;
1655     union
1656     {
1657         DWORD   dwFillColor;                    /* color in RGB or Palettized */
1658         DWORD   dwFillDepth;                    /* depth value for z-buffer */
1659         DWORD   dwFillPixel;                    /* pixel val for RGBA or RGBZ */
1660         struct IWineD3DSurface *lpDDSPattern;   /* Surface to use as pattern */
1661     } DUMMYUNIONNAME5;
1662     WINEDDCOLORKEY  ddckDestColorkey;          /* DestColorkey override */
1663     WINEDDCOLORKEY  ddckSrcColorkey;           /* SrcColorkey override */
1664 } WINEDDBLTFX,*LPWINEDDBLTFX;
1665
1666 typedef struct _WINEDDOVERLAYFX
1667 {
1668     DWORD       dwSize;                         /* size of structure */
1669     DWORD       dwAlphaEdgeBlendBitDepth;       /* Bit depth used to specify constant for alpha edge blend */
1670     DWORD       dwAlphaEdgeBlend;               /* Constant to use as alpha for edge blend */
1671     DWORD       dwReserved;
1672     DWORD       dwAlphaDestConstBitDepth;       /* Bit depth used to specify alpha constant for destination */
1673     union
1674     {
1675         DWORD   dwAlphaDestConst;               /* Constant to use as alpha channel for dest */
1676         struct IWineD3DSurface *lpDDSAlphaDest; /* Surface to use as alpha channel for dest */
1677     } DUMMYUNIONNAME1;
1678     DWORD       dwAlphaSrcConstBitDepth;        /* Bit depth used to specify alpha constant for source */
1679     union
1680     {
1681         DWORD   dwAlphaSrcConst;                /* Constant to use as alpha channel for src */
1682         struct IWineD3DSurface *lpDDSAlphaSrc;  /* Surface to use as alpha channel for src */
1683     } DUMMYUNIONNAME2;
1684     WINEDDCOLORKEY  dckDestColorkey;            /* DestColorkey override */
1685     WINEDDCOLORKEY  dckSrcColorkey;             /* DestColorkey override */
1686     DWORD       dwDDFX;                         /* Overlay FX */
1687     DWORD       dwFlags;                        /* flags */
1688 } WINEDDOVERLAYFX;
1689
1690 /* dwDDFX */
1691 /* arithmetic stretching along y axis */
1692 #define WINEDDBLTFX_ARITHSTRETCHY               0x00000001
1693 /* mirror on y axis */
1694 #define WINEDDBLTFX_MIRRORLEFTRIGHT             0x00000002
1695 /* mirror on x axis */
1696 #define WINEDDBLTFX_MIRRORUPDOWN                0x00000004
1697 /* do not tear */
1698 #define WINEDDBLTFX_NOTEARING                   0x00000008
1699 /* 180 degrees clockwise rotation */
1700 #define WINEDDBLTFX_ROTATE180                   0x00000010
1701 /* 270 degrees clockwise rotation */
1702 #define WINEDDBLTFX_ROTATE270                   0x00000020
1703 /* 90 degrees clockwise rotation */
1704 #define WINEDDBLTFX_ROTATE90                    0x00000040
1705 /* dwZBufferLow and dwZBufferHigh specify limits to the copied Z values */
1706 #define WINEDDBLTFX_ZBUFFERRANGE                0x00000080
1707 /* add dwZBufferBaseDest to every source z value before compare */
1708 #define WINEDDBLTFX_ZBUFFERBASEDEST             0x00000100
1709
1710 /* dwFlags for Blt* */
1711 #define WINEDDBLT_ALPHADEST                     0x00000001
1712 #define WINEDDBLT_ALPHADESTCONSTOVERRIDE        0x00000002
1713 #define WINEDDBLT_ALPHADESTNEG                  0x00000004
1714 #define WINEDDBLT_ALPHADESTSURFACEOVERRIDE      0x00000008
1715 #define WINEDDBLT_ALPHAEDGEBLEND                0x00000010
1716 #define WINEDDBLT_ALPHASRC                      0x00000020
1717 #define WINEDDBLT_ALPHASRCCONSTOVERRIDE         0x00000040
1718 #define WINEDDBLT_ALPHASRCNEG                   0x00000080
1719 #define WINEDDBLT_ALPHASRCSURFACEOVERRIDE       0x00000100
1720 #define WINEDDBLT_ASYNC                         0x00000200
1721 #define WINEDDBLT_COLORFILL                     0x00000400
1722 #define WINEDDBLT_DDFX                          0x00000800
1723 #define WINEDDBLT_DDROPS                        0x00001000
1724 #define WINEDDBLT_KEYDEST                       0x00002000
1725 #define WINEDDBLT_KEYDESTOVERRIDE               0x00004000
1726 #define WINEDDBLT_KEYSRC                        0x00008000
1727 #define WINEDDBLT_KEYSRCOVERRIDE                0x00010000
1728 #define WINEDDBLT_ROP                           0x00020000
1729 #define WINEDDBLT_ROTATIONANGLE                 0x00040000
1730 #define WINEDDBLT_ZBUFFER                       0x00080000
1731 #define WINEDDBLT_ZBUFFERDESTCONSTOVERRIDE      0x00100000
1732 #define WINEDDBLT_ZBUFFERDESTOVERRIDE           0x00200000
1733 #define WINEDDBLT_ZBUFFERSRCCONSTOVERRIDE       0x00400000
1734 #define WINEDDBLT_ZBUFFERSRCOVERRIDE            0x00800000
1735 #define WINEDDBLT_WAIT                          0x01000000
1736 #define WINEDDBLT_DEPTHFILL                     0x02000000
1737 #define WINEDDBLT_DONOTWAIT                     0x08000000
1738
1739 /* dwTrans for BltFast */
1740 #define WINEDDBLTFAST_NOCOLORKEY                0x00000000
1741 #define WINEDDBLTFAST_SRCCOLORKEY               0x00000001
1742 #define WINEDDBLTFAST_DESTCOLORKEY              0x00000002
1743 #define WINEDDBLTFAST_WAIT                      0x00000010
1744 #define WINEDDBLTFAST_DONOTWAIT                 0x00000020
1745
1746 /* DDCAPS.dwPalCaps */
1747 #define WINEDDPCAPS_4BIT                        0x00000001
1748 #define WINEDDPCAPS_8BITENTRIES                 0x00000002
1749 #define WINEDDPCAPS_8BIT                        0x00000004
1750 #define WINEDDPCAPS_INITIALIZE                  0x00000008
1751 #define WINEDDPCAPS_PRIMARYSURFACE              0x00000010
1752 #define WINEDDPCAPS_PRIMARYSURFACELEFT          0x00000020
1753 #define WINEDDPCAPS_ALLOW256                    0x00000040
1754 #define WINEDDPCAPS_VSYNC                       0x00000080
1755 #define WINEDDPCAPS_1BIT                        0x00000100
1756 #define WINEDDPCAPS_2BIT                        0x00000200
1757 #define WINEDDPCAPS_ALPHA                       0x00000400
1758
1759 /* DDSURFACEDESC.dwFlags */
1760 #define WINEDDSD_CAPS                           0x00000001
1761 #define WINEDDSD_HEIGHT                         0x00000002
1762 #define WINEDDSD_WIDTH                          0x00000004
1763 #define WINEDDSD_PITCH                          0x00000008
1764 #define WINEDDSD_BACKBUFFERCOUNT                0x00000020
1765 #define WINEDDSD_ZBUFFERBITDEPTH                0x00000040
1766 #define WINEDDSD_ALPHABITDEPTH                  0x00000080
1767 #define WINEDDSD_LPSURFACE                      0x00000800
1768 #define WINEDDSD_PIXELFORMAT                    0x00001000
1769 #define WINEDDSD_CKDESTOVERLAY                  0x00002000
1770 #define WINEDDSD_CKDESTBLT                      0x00004000
1771 #define WINEDDSD_CKSRCOVERLAY                   0x00008000
1772 #define WINEDDSD_CKSRCBLT                       0x00010000
1773 #define WINEDDSD_MIPMAPCOUNT                    0x00020000
1774 #define WINEDDSD_REFRESHRATE                    0x00040000
1775 #define WINEDDSD_LINEARSIZE                     0x00080000
1776 #define WINEDDSD_TEXTURESTAGE                   0x00100000
1777 #define WINEDDSD_FVF                            0x00200000
1778 #define WINEDDSD_SRCVBHANDLE                    0x00400000
1779 #define WINEDDSD_ALL                            0x007ff9ee
1780
1781 /* Set/Get Colour Key Flags */
1782 #define WINEDDCKEY_COLORSPACE                   0x00000001  /* Struct is single colour space */
1783 #define WINEDDCKEY_DESTBLT                      0x00000002  /* To be used as dest for blt */
1784 #define WINEDDCKEY_DESTOVERLAY                  0x00000004  /* To be used as dest for CK overlays */
1785 #define WINEDDCKEY_SRCBLT                       0x00000008  /* To be used as src for blt */
1786 #define WINEDDCKEY_SRCOVERLAY                   0x00000010  /* To be used as src for CK overlays */
1787
1788 /* dwFlags for GetBltStatus */
1789 #define WINEDDGBS_CANBLT                        0x00000001
1790 #define WINEDDGBS_ISBLTDONE                     0x00000002
1791
1792 /* dwFlags for GetFlipStatus */
1793 #define WINEDDGFS_CANFLIP                       1L
1794 #define WINEDDGFS_ISFLIPDONE                    2L
1795
1796 /* dwFlags for Flip */
1797 #define WINEDDFLIP_WAIT                         0x00000001
1798 #define WINEDDFLIP_EVEN                         0x00000002 /* only valid for overlay */
1799 #define WINEDDFLIP_ODD                          0x00000004 /* only valid for overlay */
1800 #define WINEDDFLIP_NOVSYNC                      0x00000008
1801 #define WINEDDFLIP_STEREO                       0x00000010
1802 #define WINEDDFLIP_DONOTWAIT                    0x00000020
1803 #define WINEDDFLIP_INTERVAL2                    0x02000000
1804 #define WINEDDFLIP_INTERVAL3                    0x03000000
1805 #define WINEDDFLIP_INTERVAL4                    0x04000000
1806
1807 #define WINEDDOVER_ALPHADEST                    0x00000001
1808 #define WINEDDOVER_ALPHADESTCONSTOVERRIDE       0x00000002
1809 #define WINEDDOVER_ALPHADESTNEG                 0x00000004
1810 #define WINEDDOVER_ALPHADESTSURFACEOVERRIDE     0x00000008
1811 #define WINEDDOVER_ALPHAEDGEBLEND               0x00000010
1812 #define WINEDDOVER_ALPHASRC                     0x00000020
1813 #define WINEDDOVER_ALPHASRCCONSTOVERRIDE        0x00000040
1814 #define WINEDDOVER_ALPHASRCNEG                  0x00000080
1815 #define WINEDDOVER_ALPHASRCSURFACEOVERRIDE      0x00000100
1816 #define WINEDDOVER_HIDE                         0x00000200
1817 #define WINEDDOVER_KEYDEST                      0x00000400
1818 #define WINEDDOVER_KEYDESTOVERRIDE              0x00000800
1819 #define WINEDDOVER_KEYSRC                       0x00001000
1820 #define WINEDDOVER_KEYSRCOVERRIDE               0x00002000
1821 #define WINEDDOVER_SHOW                         0x00004000
1822 #define WINEDDOVER_ADDDIRTYRECT                 0x00008000
1823 #define WINEDDOVER_REFRESHDIRTYRECTS            0x00010000
1824 #define WINEDDOVER_REFRESHALL                   0x00020000
1825 #define WINEDDOVER_DDFX                         0x00080000
1826 #define WINEDDOVER_AUTOFLIP                     0x00100000
1827 #define WINEDDOVER_BOB                          0x00200000
1828 #define WINEDDOVER_OVERRIDEBOBWEAVE             0x00400000
1829 #define WINEDDOVER_INTERLEAVED                  0x00800000
1830
1831 #endif