[CMAKE]
[reactos.git] / include / reactos / wine / wined3d.idl
1 /*
2 * Copyright 2002-2003 The wine-d3d team
3 * Copyright 2002-2003 Jason Edmeades
4 * Copyright 2002-2003 Raphael Junqueira
5 * Copyright 2005 Oliver Stieber
6 * Copyright 2006 Stefan Dösinger
7 * Copyright 2006 Stefan Dösinger for CodeWeavers
8 * Copyright 2007 Henri Verbeet
9 * Copyright 2008 Henri Verbeet for CodeWeavers
10 *
11 * This library is free software; you can redistribute it and/or
12 * modify it under the terms of the GNU Lesser General Public
13 * License as published by the Free Software Foundation; either
14 * version 2.1 of the License, or (at your option) any later version.
15 *
16 * This library is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 * Lesser General Public License for more details.
20 *
21 * You should have received a copy of the GNU Lesser General Public
22 * License along with this library; if not, write to the Free Software
23 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
24 */
25
26 import "unknwn.idl";
27
28 cpp_quote("#if 0")
29 typedef HANDLE HMONITOR;
30
31 typedef struct _RGNDATAHEADER
32 {
33 DWORD dwSize;
34 DWORD iType;
35 DWORD nCount;
36 DWORD nRgnSize;
37 RECT rcBound;
38 } RGNDATAHEADER;
39
40 typedef struct _RGNDATA
41 {
42 RGNDATAHEADER rdh;
43 char Buffer[1];
44 } RGNDATA;
45
46 typedef struct _LUID
47 {
48 DWORD LowPart;
49 LONG HighPart;
50 } LUID, *PLUID;
51 cpp_quote("#endif")
52
53 cpp_quote("#define WINED3D_OK S_OK")
54
55 const UINT _FACWINED3D = 0x876;
56 cpp_quote("#define MAKE_WINED3DSTATUS(code) MAKE_HRESULT(0, _FACWINED3D, code)")
57 cpp_quote("#define WINED3DOK_NOAUTOGEN MAKE_WINED3DSTATUS(2159)")
58
59 cpp_quote("#define MAKE_WINED3DHRESULT(code) MAKE_HRESULT(1, _FACWINED3D, code)")
60 cpp_quote("#define WINED3DERR_WRONGTEXTUREFORMAT MAKE_WINED3DHRESULT(2072)")
61 cpp_quote("#define WINED3DERR_UNSUPPORTEDCOLOROPERATION MAKE_WINED3DHRESULT(2073)")
62 cpp_quote("#define WINED3DERR_UNSUPPORTEDCOLORARG MAKE_WINED3DHRESULT(2074)")
63 cpp_quote("#define WINED3DERR_UNSUPPORTEDALPHAOPERATION MAKE_WINED3DHRESULT(2075)")
64 cpp_quote("#define WINED3DERR_UNSUPPORTEDALPHAARG MAKE_WINED3DHRESULT(2076)")
65 cpp_quote("#define WINED3DERR_TOOMANYOPERATIONS MAKE_WINED3DHRESULT(2077)")
66 cpp_quote("#define WINED3DERR_CONFLICTINGTEXTUREFILTER MAKE_WINED3DHRESULT(2078)")
67 cpp_quote("#define WINED3DERR_UNSUPPORTEDFACTORVALUE MAKE_WINED3DHRESULT(2079)")
68 cpp_quote("#define WINED3DERR_CONFLICTINGRENDERSTATE MAKE_WINED3DHRESULT(2081)")
69 cpp_quote("#define WINED3DERR_UNSUPPORTEDTEXTUREFILTER MAKE_WINED3DHRESULT(2082)")
70 cpp_quote("#define WINED3DERR_CONFLICTINGTEXTUREPALETTE MAKE_WINED3DHRESULT(2086)")
71 cpp_quote("#define WINED3DERR_DRIVERINTERNALERROR MAKE_WINED3DHRESULT(2087)")
72 cpp_quote("#define WINED3DERR_NOTFOUND MAKE_WINED3DHRESULT(2150)")
73 cpp_quote("#define WINED3DERR_MOREDATA MAKE_WINED3DHRESULT(2151)")
74 cpp_quote("#define WINED3DERR_DEVICELOST MAKE_WINED3DHRESULT(2152)")
75 cpp_quote("#define WINED3DERR_DEVICENOTRESET MAKE_WINED3DHRESULT(2153)")
76 cpp_quote("#define WINED3DERR_NOTAVAILABLE MAKE_WINED3DHRESULT(2154)")
77 cpp_quote("#define WINED3DERR_OUTOFVIDEOMEMORY MAKE_WINED3DHRESULT(380)")
78 cpp_quote("#define WINED3DERR_INVALIDDEVICE MAKE_WINED3DHRESULT(2155)")
79 cpp_quote("#define WINED3DERR_INVALIDCALL MAKE_WINED3DHRESULT(2156)")
80 cpp_quote("#define WINED3DERR_DRIVERINVALIDCALL MAKE_WINED3DHRESULT(2157)")
81 cpp_quote("#define WINED3DERR_WASSTILLDRAWING MAKE_WINED3DHRESULT(540)")
82 cpp_quote("#define WINEDDERR_NOTAOVERLAYSURFACE MAKE_WINED3DHRESULT(580)")
83 cpp_quote("#define WINEDDERR_NOTLOCKED MAKE_WINED3DHRESULT(584)")
84 cpp_quote("#define WINEDDERR_NODC MAKE_WINED3DHRESULT(586)")
85 cpp_quote("#define WINEDDERR_DCALREADYCREATED MAKE_WINED3DHRESULT(620)")
86 cpp_quote("#define WINEDDERR_NOTFLIPPABLE MAKE_WINED3DHRESULT(582)")
87 cpp_quote("#define WINEDDERR_SURFACEBUSY MAKE_WINED3DHRESULT(430)")
88 cpp_quote("#define WINEDDERR_INVALIDRECT MAKE_WINED3DHRESULT(150)")
89 cpp_quote("#define WINEDDERR_NOCLIPLIST MAKE_WINED3DHRESULT(205)")
90 cpp_quote("#define WINEDDERR_OVERLAYNOTVISIBLE MAKE_WINED3DHRESULT(577)")
91
92 typedef DWORD WINED3DCOLOR;
93
94 typedef enum _WINED3DLIGHTTYPE
95 {
96 WINED3DLIGHT_POINT = 1,
97 WINED3DLIGHT_SPOT = 2,
98 WINED3DLIGHT_DIRECTIONAL = 3,
99 WINED3DLIGHT_PARALLELPOINT = 4, /* D3D7 */
100 WINED3DLIGHT_GLSPOT = 5, /* D3D7 */
101 WINED3DLIGHT_FORCE_DWORD = 0x7fffffff
102 } WINED3DLIGHTTYPE;
103
104 typedef enum _WINED3DPRIMITIVETYPE
105 {
106 WINED3DPT_UNDEFINED = 0,
107 WINED3DPT_POINTLIST = 1,
108 WINED3DPT_LINELIST = 2,
109 WINED3DPT_LINESTRIP = 3,
110 WINED3DPT_TRIANGLELIST = 4,
111 WINED3DPT_TRIANGLESTRIP = 5,
112 WINED3DPT_TRIANGLEFAN = 6,
113 WINED3DPT_LINELIST_ADJ = 10,
114 WINED3DPT_LINESTRIP_ADJ = 11,
115 WINED3DPT_TRIANGLELIST_ADJ = 12,
116 WINED3DPT_TRIANGLESTRIP_ADJ = 13,
117 WINED3DPT_FORCE_DWORD = 0x7fffffff
118 } WINED3DPRIMITIVETYPE;
119
120 typedef enum _WINED3DDEVTYPE
121 {
122 WINED3DDEVTYPE_HAL = 1,
123 WINED3DDEVTYPE_REF = 2,
124 WINED3DDEVTYPE_SW = 3,
125 WINED3DDEVTYPE_NULLREF = 4,
126 WINED3DDEVTYPE_FORCE_DWORD = 0xffffffff
127 } WINED3DDEVTYPE;
128
129 typedef enum _WINED3DDEGREETYPE
130 {
131 WINED3DDEGREE_LINEAR = 1,
132 WINED3DDEGREE_QUADRATIC = 2,
133 WINED3DDEGREE_CUBIC = 3,
134 WINED3DDEGREE_QUINTIC = 5,
135 WINED3DDEGREE_FORCE_DWORD = 0x7fffffff
136 } WINED3DDEGREETYPE;
137
138 enum wined3d_format_id
139 {
140 WINED3DFMT_UNKNOWN,
141 WINED3DFMT_B8G8R8_UNORM,
142 WINED3DFMT_B5G5R5X1_UNORM,
143 WINED3DFMT_B4G4R4A4_UNORM,
144 WINED3DFMT_B2G3R3_UNORM,
145 WINED3DFMT_B2G3R3A8_UNORM,
146 WINED3DFMT_B4G4R4X4_UNORM,
147 WINED3DFMT_R8G8B8X8_UNORM,
148 WINED3DFMT_B10G10R10A2_UNORM,
149 WINED3DFMT_P8_UINT_A8_UNORM,
150 WINED3DFMT_P8_UINT,
151 WINED3DFMT_L8_UNORM,
152 WINED3DFMT_L8A8_UNORM,
153 WINED3DFMT_L4A4_UNORM,
154 WINED3DFMT_R5G5_SNORM_L6_UNORM,
155 WINED3DFMT_R8G8_SNORM_L8X8_UNORM,
156 WINED3DFMT_R10G11B11_SNORM,
157 WINED3DFMT_R10G10B10_SNORM_A2_UNORM,
158 WINED3DFMT_D16_LOCKABLE,
159 WINED3DFMT_D32_UNORM,
160 WINED3DFMT_S1_UINT_D15_UNORM,
161 WINED3DFMT_X8D24_UNORM,
162 WINED3DFMT_S4X4_UINT_D24_UNORM,
163 WINED3DFMT_L16_UNORM,
164 WINED3DFMT_S8_UINT_D24_FLOAT,
165 WINED3DFMT_VERTEXDATA,
166 WINED3DFMT_R8G8_SNORM_Cx,
167 WINED3DFMT_R32G32B32A32_TYPELESS,
168 WINED3DFMT_R32G32B32A32_FLOAT,
169 WINED3DFMT_R32G32B32A32_UINT,
170 WINED3DFMT_R32G32B32A32_SINT,
171 WINED3DFMT_R32G32B32_TYPELESS,
172 WINED3DFMT_R32G32B32_FLOAT,
173 WINED3DFMT_R32G32B32_UINT,
174 WINED3DFMT_R32G32B32_SINT,
175 WINED3DFMT_R16G16B16A16_TYPELESS,
176 WINED3DFMT_R16G16B16A16_FLOAT,
177 WINED3DFMT_R16G16B16A16_UNORM,
178 WINED3DFMT_R16G16B16A16_UINT,
179 WINED3DFMT_R16G16B16A16_SNORM,
180 WINED3DFMT_R16G16B16A16_SINT,
181 WINED3DFMT_R32G32_TYPELESS,
182 WINED3DFMT_R32G32_FLOAT,
183 WINED3DFMT_R32G32_UINT,
184 WINED3DFMT_R32G32_SINT,
185 WINED3DFMT_R32G8X24_TYPELESS,
186 WINED3DFMT_D32_FLOAT_S8X24_UINT,
187 WINED3DFMT_R32_FLOAT_X8X24_TYPELESS,
188 WINED3DFMT_X32_TYPELESS_G8X24_UINT,
189 WINED3DFMT_R10G10B10A2_TYPELESS,
190 WINED3DFMT_R10G10B10A2_UNORM,
191 WINED3DFMT_R10G10B10A2_UINT,
192 WINED3DFMT_R10G10B10A2_SNORM,
193 WINED3DFMT_R11G11B10_FLOAT,
194 WINED3DFMT_R8G8B8A8_TYPELESS,
195 WINED3DFMT_R8G8B8A8_UNORM,
196 WINED3DFMT_R8G8B8A8_UNORM_SRGB,
197 WINED3DFMT_R8G8B8A8_UINT,
198 WINED3DFMT_R8G8B8A8_SNORM,
199 WINED3DFMT_R8G8B8A8_SINT,
200 WINED3DFMT_R16G16_TYPELESS,
201 WINED3DFMT_R16G16_FLOAT,
202 WINED3DFMT_R16G16_UNORM,
203 WINED3DFMT_R16G16_UINT,
204 WINED3DFMT_R16G16_SNORM,
205 WINED3DFMT_R16G16_SINT,
206 WINED3DFMT_R32_TYPELESS,
207 WINED3DFMT_D32_FLOAT,
208 WINED3DFMT_R32_FLOAT,
209 WINED3DFMT_R32_UINT,
210 WINED3DFMT_R32_SINT,
211 WINED3DFMT_R24G8_TYPELESS,
212 WINED3DFMT_D24_UNORM_S8_UINT,
213 WINED3DFMT_R24_UNORM_X8_TYPELESS,
214 WINED3DFMT_X24_TYPELESS_G8_UINT,
215 WINED3DFMT_R8G8_TYPELESS,
216 WINED3DFMT_R8G8_UNORM,
217 WINED3DFMT_R8G8_UINT,
218 WINED3DFMT_R8G8_SNORM,
219 WINED3DFMT_R8G8_SINT,
220 WINED3DFMT_R16_TYPELESS,
221 WINED3DFMT_R16_FLOAT,
222 WINED3DFMT_D16_UNORM,
223 WINED3DFMT_R16_UNORM,
224 WINED3DFMT_R16_UINT,
225 WINED3DFMT_R16_SNORM,
226 WINED3DFMT_R16_SINT,
227 WINED3DFMT_R8_TYPELESS,
228 WINED3DFMT_R8_UNORM,
229 WINED3DFMT_R8_UINT,
230 WINED3DFMT_R8_SNORM,
231 WINED3DFMT_R8_SINT,
232 WINED3DFMT_A8_UNORM,
233 WINED3DFMT_R1_UNORM,
234 WINED3DFMT_R9G9B9E5_SHAREDEXP,
235 WINED3DFMT_R8G8_B8G8_UNORM,
236 WINED3DFMT_G8R8_G8B8_UNORM,
237 WINED3DFMT_BC1_TYPELESS,
238 WINED3DFMT_BC1_UNORM,
239 WINED3DFMT_BC1_UNORM_SRGB,
240 WINED3DFMT_BC2_TYPELESS,
241 WINED3DFMT_BC2_UNORM,
242 WINED3DFMT_BC2_UNORM_SRGB,
243 WINED3DFMT_BC3_TYPELESS,
244 WINED3DFMT_BC3_UNORM,
245 WINED3DFMT_BC3_UNORM_SRGB,
246 WINED3DFMT_BC4_TYPELESS,
247 WINED3DFMT_BC4_UNORM,
248 WINED3DFMT_BC4_SNORM,
249 WINED3DFMT_BC5_TYPELESS,
250 WINED3DFMT_BC5_UNORM,
251 WINED3DFMT_BC5_SNORM,
252 WINED3DFMT_B5G6R5_UNORM,
253 WINED3DFMT_B5G5R5A1_UNORM,
254 WINED3DFMT_B8G8R8A8_UNORM,
255 WINED3DFMT_B8G8R8X8_UNORM,
256 /* FOURCC formats. */
257 WINED3DFMT_UYVY = 0x59565955, /* UYVY */
258 WINED3DFMT_YUY2 = 0x32595559, /* YUY2 */
259 WINED3DFMT_YV12 = 0x32315659, /* YV12 */
260 WINED3DFMT_DXT1 = 0x31545844, /* DXT1 */
261 WINED3DFMT_DXT2 = 0x32545844, /* DXT2 */
262 WINED3DFMT_DXT3 = 0x33545844, /* DXT3 */
263 WINED3DFMT_DXT4 = 0x34545844, /* DXT4 */
264 WINED3DFMT_DXT5 = 0x35545844, /* DXT5 */
265 WINED3DFMT_MULTI2_ARGB8 = 0x3154454d, /* MET1 */
266 WINED3DFMT_G8R8_G8B8 = 0x42475247, /* GRGB */
267 WINED3DFMT_R8G8_B8G8 = 0x47424752, /* RGBG */
268 WINED3DFMT_ATI2N = 0x32495441, /* ATI2 */
269 WINED3DFMT_INST = 0x54534e49, /* INST */
270 WINED3DFMT_NVDB = 0x4244564e, /* NVDB */
271 WINED3DFMT_NVHU = 0x5548564e, /* NVHU */
272 WINED3DFMT_NVHS = 0x5348564e, /* NVHS */
273
274 WINED3DFMT_FORCE_DWORD = 0xffffffff
275 };
276
277 typedef enum _WINED3DRENDERSTATETYPE
278 {
279 WINED3DRS_ANTIALIAS = 2, /* d3d7 */
280 WINED3DRS_TEXTUREPERSPECTIVE = 4, /* d3d7 */
281 WINED3DRS_WRAPU = 5, /* d3d7 */
282 WINED3DRS_WRAPV = 6, /* d3d7 */
283 WINED3DRS_ZENABLE = 7,
284 WINED3DRS_FILLMODE = 8,
285 WINED3DRS_SHADEMODE = 9,
286 WINED3DRS_LINEPATTERN = 10, /* d3d7, d3d8 */
287 WINED3DRS_MONOENABLE = 11, /* d3d7 */
288 WINED3DRS_ROP2 = 12, /* d3d7 */
289 WINED3DRS_PLANEMASK = 13, /* d3d7 */
290 WINED3DRS_ZWRITEENABLE = 14,
291 WINED3DRS_ALPHATESTENABLE = 15,
292 WINED3DRS_LASTPIXEL = 16,
293 WINED3DRS_SRCBLEND = 19,
294 WINED3DRS_DESTBLEND = 20,
295 WINED3DRS_CULLMODE = 22,
296 WINED3DRS_ZFUNC = 23,
297 WINED3DRS_ALPHAREF = 24,
298 WINED3DRS_ALPHAFUNC = 25,
299 WINED3DRS_DITHERENABLE = 26,
300 WINED3DRS_ALPHABLENDENABLE = 27,
301 WINED3DRS_FOGENABLE = 28,
302 WINED3DRS_SPECULARENABLE = 29,
303 WINED3DRS_ZVISIBLE = 30, /* d3d7, d3d8 */
304 WINED3DRS_SUBPIXEL = 31, /* d3d7 */
305 WINED3DRS_SUBPIXELX = 32, /* d3d7 */
306 WINED3DRS_STIPPLEDALPHA = 33, /* d3d7 */
307 WINED3DRS_FOGCOLOR = 34,
308 WINED3DRS_FOGTABLEMODE = 35,
309 WINED3DRS_FOGSTART = 36,
310 WINED3DRS_FOGEND = 37,
311 WINED3DRS_FOGDENSITY = 38,
312 WINED3DRS_STIPPLEENABLE = 39, /* d3d7 */
313 WINED3DRS_EDGEANTIALIAS = 40, /* d3d7, d3d8 */
314 WINED3DRS_COLORKEYENABLE = 41, /* d3d7 */
315 WINED3DRS_MIPMAPLODBIAS = 46, /* d3d7 */
316 WINED3DRS_ZBIAS = 47, /* d3d7, d3d8 */
317 WINED3DRS_RANGEFOGENABLE = 48,
318 WINED3DRS_ANISOTROPY = 49, /* d3d7 */
319 WINED3DRS_FLUSHBATCH = 50, /* d3d7 */
320 WINED3DRS_TRANSLUCENTSORTINDEPENDENT = 51, /* d3d7 */
321 WINED3DRS_STENCILENABLE = 52,
322 WINED3DRS_STENCILFAIL = 53,
323 WINED3DRS_STENCILZFAIL = 54,
324 WINED3DRS_STENCILPASS = 55,
325 WINED3DRS_STENCILFUNC = 56,
326 WINED3DRS_STENCILREF = 57,
327 WINED3DRS_STENCILMASK = 58,
328 WINED3DRS_STENCILWRITEMASK = 59,
329 WINED3DRS_TEXTUREFACTOR = 60,
330 WINED3DRS_WRAP0 = 128,
331 WINED3DRS_WRAP1 = 129,
332 WINED3DRS_WRAP2 = 130,
333 WINED3DRS_WRAP3 = 131,
334 WINED3DRS_WRAP4 = 132,
335 WINED3DRS_WRAP5 = 133,
336 WINED3DRS_WRAP6 = 134,
337 WINED3DRS_WRAP7 = 135,
338 WINED3DRS_CLIPPING = 136,
339 WINED3DRS_LIGHTING = 137,
340 WINED3DRS_EXTENTS = 138, /* d3d7 */
341 WINED3DRS_AMBIENT = 139,
342 WINED3DRS_FOGVERTEXMODE = 140,
343 WINED3DRS_COLORVERTEX = 141,
344 WINED3DRS_LOCALVIEWER = 142,
345 WINED3DRS_NORMALIZENORMALS = 143,
346 WINED3DRS_COLORKEYBLENDENABLE = 144, /* d3d7 */
347 WINED3DRS_DIFFUSEMATERIALSOURCE = 145,
348 WINED3DRS_SPECULARMATERIALSOURCE = 146,
349 WINED3DRS_AMBIENTMATERIALSOURCE = 147,
350 WINED3DRS_EMISSIVEMATERIALSOURCE = 148,
351 WINED3DRS_VERTEXBLEND = 151,
352 WINED3DRS_CLIPPLANEENABLE = 152,
353 WINED3DRS_SOFTWAREVERTEXPROCESSING = 153, /* d3d8 */
354 WINED3DRS_POINTSIZE = 154,
355 WINED3DRS_POINTSIZE_MIN = 155,
356 WINED3DRS_POINTSPRITEENABLE = 156,
357 WINED3DRS_POINTSCALEENABLE = 157,
358 WINED3DRS_POINTSCALE_A = 158,
359 WINED3DRS_POINTSCALE_B = 159,
360 WINED3DRS_POINTSCALE_C = 160,
361 WINED3DRS_MULTISAMPLEANTIALIAS = 161,
362 WINED3DRS_MULTISAMPLEMASK = 162,
363 WINED3DRS_PATCHEDGESTYLE = 163,
364 WINED3DRS_PATCHSEGMENTS = 164, /* d3d8 */
365 WINED3DRS_DEBUGMONITORTOKEN = 165,
366 WINED3DRS_POINTSIZE_MAX = 166,
367 WINED3DRS_INDEXEDVERTEXBLENDENABLE = 167,
368 WINED3DRS_COLORWRITEENABLE = 168,
369 WINED3DRS_TWEENFACTOR = 170,
370 WINED3DRS_BLENDOP = 171,
371 WINED3DRS_POSITIONDEGREE = 172,
372 WINED3DRS_NORMALDEGREE = 173,
373 WINED3DRS_SCISSORTESTENABLE = 174,
374 WINED3DRS_SLOPESCALEDEPTHBIAS = 175,
375 WINED3DRS_ANTIALIASEDLINEENABLE = 176,
376 WINED3DRS_MINTESSELLATIONLEVEL = 178,
377 WINED3DRS_MAXTESSELLATIONLEVEL = 179,
378 WINED3DRS_ADAPTIVETESS_X = 180,
379 WINED3DRS_ADAPTIVETESS_Y = 181,
380 WINED3DRS_ADAPTIVETESS_Z = 182,
381 WINED3DRS_ADAPTIVETESS_W = 183,
382 WINED3DRS_ENABLEADAPTIVETESSELLATION = 184,
383 WINED3DRS_TWOSIDEDSTENCILMODE = 185,
384 WINED3DRS_CCW_STENCILFAIL = 186,
385 WINED3DRS_CCW_STENCILZFAIL = 187,
386 WINED3DRS_CCW_STENCILPASS = 188,
387 WINED3DRS_CCW_STENCILFUNC = 189,
388 WINED3DRS_COLORWRITEENABLE1 = 190,
389 WINED3DRS_COLORWRITEENABLE2 = 191,
390 WINED3DRS_COLORWRITEENABLE3 = 192,
391 WINED3DRS_BLENDFACTOR = 193,
392 WINED3DRS_SRGBWRITEENABLE = 194,
393 WINED3DRS_DEPTHBIAS = 195,
394 WINED3DRS_WRAP8 = 198,
395 WINED3DRS_WRAP9 = 199,
396 WINED3DRS_WRAP10 = 200,
397 WINED3DRS_WRAP11 = 201,
398 WINED3DRS_WRAP12 = 202,
399 WINED3DRS_WRAP13 = 203,
400 WINED3DRS_WRAP14 = 204,
401 WINED3DRS_WRAP15 = 205,
402 WINED3DRS_SEPARATEALPHABLENDENABLE = 206,
403 WINED3DRS_SRCBLENDALPHA = 207,
404 WINED3DRS_DESTBLENDALPHA = 208,
405 WINED3DRS_BLENDOPALPHA = 209,
406 WINED3DRS_FORCE_DWORD = 0x7fffffff
407 } WINED3DRENDERSTATETYPE;
408 const UINT WINEHIGHEST_RENDER_STATE = WINED3DRS_BLENDOPALPHA;
409
410 typedef enum _WINED3DBLEND
411 {
412 WINED3DBLEND_ZERO = 1,
413 WINED3DBLEND_ONE = 2,
414 WINED3DBLEND_SRCCOLOR = 3,
415 WINED3DBLEND_INVSRCCOLOR = 4,
416 WINED3DBLEND_SRCALPHA = 5,
417 WINED3DBLEND_INVSRCALPHA = 6,
418 WINED3DBLEND_DESTALPHA = 7,
419 WINED3DBLEND_INVDESTALPHA = 8,
420 WINED3DBLEND_DESTCOLOR = 9,
421 WINED3DBLEND_INVDESTCOLOR = 10,
422 WINED3DBLEND_SRCALPHASAT = 11,
423 WINED3DBLEND_BOTHSRCALPHA = 12,
424 WINED3DBLEND_BOTHINVSRCALPHA = 13,
425 WINED3DBLEND_BLENDFACTOR = 14,
426 WINED3DBLEND_INVBLENDFACTOR = 15,
427 WINED3DBLEND_FORCE_DWORD = 0x7fffffff
428 } WINED3DBLEND;
429
430 typedef enum _WINED3DBLENDOP
431 {
432 WINED3DBLENDOP_ADD = 1,
433 WINED3DBLENDOP_SUBTRACT = 2,
434 WINED3DBLENDOP_REVSUBTRACT = 3,
435 WINED3DBLENDOP_MIN = 4,
436 WINED3DBLENDOP_MAX = 5,
437 WINED3DBLENDOP_FORCE_DWORD = 0x7fffffff
438 } WINED3DBLENDOP;
439
440 typedef enum _WINED3DVERTEXBLENDFLAGS
441 {
442 WINED3DVBF_DISABLE = 0,
443 WINED3DVBF_1WEIGHTS = 1,
444 WINED3DVBF_2WEIGHTS = 2,
445 WINED3DVBF_3WEIGHTS = 3,
446 WINED3DVBF_TWEENING = 255,
447 WINED3DVBF_0WEIGHTS = 256
448 } WINED3DVERTEXBLENDFLAGS;
449
450 typedef enum _WINED3DCMPFUNC
451 {
452 WINED3DCMP_NEVER = 1,
453 WINED3DCMP_LESS = 2,
454 WINED3DCMP_EQUAL = 3,
455 WINED3DCMP_LESSEQUAL = 4,
456 WINED3DCMP_GREATER = 5,
457 WINED3DCMP_NOTEQUAL = 6,
458 WINED3DCMP_GREATEREQUAL = 7,
459 WINED3DCMP_ALWAYS = 8,
460 WINED3DCMP_FORCE_DWORD = 0x7fffffff
461 } WINED3DCMPFUNC;
462
463 typedef enum _WINED3DZBUFFERTYPE
464 {
465 WINED3DZB_FALSE = 0,
466 WINED3DZB_TRUE = 1,
467 WINED3DZB_USEW = 2,
468 WINED3DZB_FORCE_DWORD = 0x7fffffff
469 } WINED3DZBUFFERTYPE;
470
471 typedef enum _WINED3DFOGMODE
472 {
473 WINED3DFOG_NONE = 0,
474 WINED3DFOG_EXP = 1,
475 WINED3DFOG_EXP2 = 2,
476 WINED3DFOG_LINEAR = 3,
477 WINED3DFOG_FORCE_DWORD = 0x7fffffff
478 } WINED3DFOGMODE;
479
480 typedef enum _WINED3DSHADEMODE
481 {
482 WINED3DSHADE_FLAT = 1,
483 WINED3DSHADE_GOURAUD = 2,
484 WINED3DSHADE_PHONG = 3,
485 WINED3DSHADE_FORCE_DWORD = 0x7fffffff
486 } WINED3DSHADEMODE;
487
488 typedef enum _WINED3DFILLMODE
489 {
490 WINED3DFILL_POINT = 1,
491 WINED3DFILL_WIREFRAME = 2,
492 WINED3DFILL_SOLID = 3,
493 WINED3DFILL_FORCE_DWORD = 0x7fffffff
494 } WINED3DFILLMODE;
495
496 typedef enum _WINED3DCULL
497 {
498 WINED3DCULL_NONE = 1,
499 WINED3DCULL_CW = 2,
500 WINED3DCULL_CCW = 3,
501 WINED3DCULL_FORCE_DWORD = 0x7fffffff
502 } WINED3DCULL;
503
504 typedef enum _WINED3DSTENCILOP
505 {
506 WINED3DSTENCILOP_KEEP = 1,
507 WINED3DSTENCILOP_ZERO = 2,
508 WINED3DSTENCILOP_REPLACE = 3,
509 WINED3DSTENCILOP_INCRSAT = 4,
510 WINED3DSTENCILOP_DECRSAT = 5,
511 WINED3DSTENCILOP_INVERT = 6,
512 WINED3DSTENCILOP_INCR = 7,
513 WINED3DSTENCILOP_DECR = 8,
514 WINED3DSTENCILOP_FORCE_DWORD = 0x7fffffff
515 } WINED3DSTENCILOP;
516
517 typedef enum _WINED3DMATERIALCOLORSOURCE
518 {
519 WINED3DMCS_MATERIAL = 0,
520 WINED3DMCS_COLOR1 = 1,
521 WINED3DMCS_COLOR2 = 2,
522 WINED3DMCS_FORCE_DWORD = 0x7fffffff
523 } WINED3DMATERIALCOLORSOURCE;
524
525 typedef enum _WINED3DPATCHEDGESTYLE
526 {
527 WINED3DPATCHEDGE_DISCRETE = 0,
528 WINED3DPATCHEDGE_CONTINUOUS = 1,
529 WINED3DPATCHEDGE_FORCE_DWORD = 0x7fffffff
530 } WINED3DPATCHEDGESTYLE;
531
532 typedef enum _WINED3DBACKBUFFER_TYPE
533 {
534 WINED3DBACKBUFFER_TYPE_MONO = 0,
535 WINED3DBACKBUFFER_TYPE_LEFT = 1,
536 WINED3DBACKBUFFER_TYPE_RIGHT = 2,
537 WINED3DBACKBUFFER_TYPE_FORCE_DWORD = 0x7fffffff
538 } WINED3DBACKBUFFER_TYPE;
539
540 typedef enum _WINED3DSWAPEFFECT
541 {
542 WINED3DSWAPEFFECT_DISCARD = 1,
543 WINED3DSWAPEFFECT_FLIP = 2,
544 WINED3DSWAPEFFECT_COPY = 3,
545 WINED3DSWAPEFFECT_COPY_VSYNC = 4,
546 WINED3DSWAPEFFECT_FORCE_DWORD = 0xffffffff
547 } WINED3DSWAPEFFECT;
548
549 typedef enum _WINED3DSAMPLERSTATETYPE
550 {
551 WINED3DSAMP_ADDRESSU = 1,
552 WINED3DSAMP_ADDRESSV = 2,
553 WINED3DSAMP_ADDRESSW = 3,
554 WINED3DSAMP_BORDERCOLOR = 4,
555 WINED3DSAMP_MAGFILTER = 5,
556 WINED3DSAMP_MINFILTER = 6,
557 WINED3DSAMP_MIPFILTER = 7,
558 WINED3DSAMP_MIPMAPLODBIAS = 8,
559 WINED3DSAMP_MAXMIPLEVEL = 9,
560 WINED3DSAMP_MAXANISOTROPY = 10,
561 WINED3DSAMP_SRGBTEXTURE = 11,
562 WINED3DSAMP_ELEMENTINDEX = 12,
563 WINED3DSAMP_DMAPOFFSET = 13,
564 WINED3DSAMP_FORCE_DWORD = 0x7fffffff,
565 } WINED3DSAMPLERSTATETYPE;
566 const UINT WINED3D_HIGHEST_SAMPLER_STATE = WINED3DSAMP_DMAPOFFSET;
567
568 typedef enum _WINED3DMULTISAMPLE_TYPE
569 {
570 WINED3DMULTISAMPLE_NONE = 0,
571 WINED3DMULTISAMPLE_NONMASKABLE = 1,
572 WINED3DMULTISAMPLE_2_SAMPLES = 2,
573 WINED3DMULTISAMPLE_3_SAMPLES = 3,
574 WINED3DMULTISAMPLE_4_SAMPLES = 4,
575 WINED3DMULTISAMPLE_5_SAMPLES = 5,
576 WINED3DMULTISAMPLE_6_SAMPLES = 6,
577 WINED3DMULTISAMPLE_7_SAMPLES = 7,
578 WINED3DMULTISAMPLE_8_SAMPLES = 8,
579 WINED3DMULTISAMPLE_9_SAMPLES = 9,
580 WINED3DMULTISAMPLE_10_SAMPLES = 10,
581 WINED3DMULTISAMPLE_11_SAMPLES = 11,
582 WINED3DMULTISAMPLE_12_SAMPLES = 12,
583 WINED3DMULTISAMPLE_13_SAMPLES = 13,
584 WINED3DMULTISAMPLE_14_SAMPLES = 14,
585 WINED3DMULTISAMPLE_15_SAMPLES = 15,
586 WINED3DMULTISAMPLE_16_SAMPLES = 16,
587 WINED3DMULTISAMPLE_FORCE_DWORD = 0xffffffff
588 } WINED3DMULTISAMPLE_TYPE;
589
590 typedef enum _WINED3DTEXTURESTAGESTATETYPE
591 {
592 WINED3DTSS_COLOROP = 0,
593 WINED3DTSS_COLORARG1 = 1,
594 WINED3DTSS_COLORARG2 = 2,
595 WINED3DTSS_ALPHAOP = 3,
596 WINED3DTSS_ALPHAARG1 = 4,
597 WINED3DTSS_ALPHAARG2 = 5,
598 WINED3DTSS_BUMPENVMAT00 = 6,
599 WINED3DTSS_BUMPENVMAT01 = 7,
600 WINED3DTSS_BUMPENVMAT10 = 8,
601 WINED3DTSS_BUMPENVMAT11 = 9,
602 WINED3DTSS_TEXCOORDINDEX = 10,
603 WINED3DTSS_BUMPENVLSCALE = 11,
604 WINED3DTSS_BUMPENVLOFFSET = 12,
605 WINED3DTSS_TEXTURETRANSFORMFLAGS = 13,
606 WINED3DTSS_COLORARG0 = 14,
607 WINED3DTSS_ALPHAARG0 = 15,
608 WINED3DTSS_RESULTARG = 16,
609 WINED3DTSS_CONSTANT = 17,
610 WINED3DTSS_FORCE_DWORD = 0x7fffffff
611 } WINED3DTEXTURESTAGESTATETYPE;
612 const UINT WINED3D_HIGHEST_TEXTURE_STATE = WINED3DTSS_CONSTANT;
613
614 typedef enum _WINED3DTEXTURETRANSFORMFLAGS
615 {
616 WINED3DTTFF_DISABLE = 0,
617 WINED3DTTFF_COUNT1 = 1,
618 WINED3DTTFF_COUNT2 = 2,
619 WINED3DTTFF_COUNT3 = 3,
620 WINED3DTTFF_COUNT4 = 4,
621 WINED3DTTFF_PROJECTED = 256,
622 WINED3DTTFF_FORCE_DWORD = 0x7fffffff
623 } WINED3DTEXTURETRANSFORMFLAGS;
624
625 typedef enum _WINED3DTEXTUREOP
626 {
627 WINED3DTOP_DISABLE = 1,
628 WINED3DTOP_SELECTARG1 = 2,
629 WINED3DTOP_SELECTARG2 = 3,
630 WINED3DTOP_MODULATE = 4,
631 WINED3DTOP_MODULATE2X = 5,
632 WINED3DTOP_MODULATE4X = 6,
633 WINED3DTOP_ADD = 7,
634 WINED3DTOP_ADDSIGNED = 8,
635 WINED3DTOP_ADDSIGNED2X = 9,
636 WINED3DTOP_SUBTRACT = 10,
637 WINED3DTOP_ADDSMOOTH = 11,
638 WINED3DTOP_BLENDDIFFUSEALPHA = 12,
639 WINED3DTOP_BLENDTEXTUREALPHA = 13,
640 WINED3DTOP_BLENDFACTORALPHA = 14,
641 WINED3DTOP_BLENDTEXTUREALPHAPM = 15,
642 WINED3DTOP_BLENDCURRENTALPHA = 16,
643 WINED3DTOP_PREMODULATE = 17,
644 WINED3DTOP_MODULATEALPHA_ADDCOLOR = 18,
645 WINED3DTOP_MODULATECOLOR_ADDALPHA = 19,
646 WINED3DTOP_MODULATEINVALPHA_ADDCOLOR = 20,
647 WINED3DTOP_MODULATEINVCOLOR_ADDALPHA = 21,
648 WINED3DTOP_BUMPENVMAP = 22,
649 WINED3DTOP_BUMPENVMAPLUMINANCE = 23,
650 WINED3DTOP_DOTPRODUCT3 = 24,
651 WINED3DTOP_MULTIPLYADD = 25,
652 WINED3DTOP_LERP = 26,
653 WINED3DTOP_FORCE_DWORD = 0x7fffffff,
654 } WINED3DTEXTUREOP;
655
656 typedef enum _WINED3DTEXTUREADDRESS
657 {
658 WINED3DTADDRESS_WRAP = 1,
659 WINED3DTADDRESS_MIRROR = 2,
660 WINED3DTADDRESS_CLAMP = 3,
661 WINED3DTADDRESS_BORDER = 4,
662 WINED3DTADDRESS_MIRRORONCE = 5,
663 WINED3DTADDRESS_FORCE_DWORD = 0x7fffffff
664 } WINED3DTEXTUREADDRESS;
665
666 typedef enum _WINED3DTRANSFORMSTATETYPE
667 {
668 WINED3DTS_VIEW = 2,
669 WINED3DTS_PROJECTION = 3,
670 WINED3DTS_TEXTURE0 = 16,
671 WINED3DTS_TEXTURE1 = 17,
672 WINED3DTS_TEXTURE2 = 18,
673 WINED3DTS_TEXTURE3 = 19,
674 WINED3DTS_TEXTURE4 = 20,
675 WINED3DTS_TEXTURE5 = 21,
676 WINED3DTS_TEXTURE6 = 22,
677 WINED3DTS_TEXTURE7 = 23,
678 WINED3DTS_WORLD = 256, /*WINED3DTS_WORLDMATRIX(0)*/
679 WINED3DTS_WORLD1 = 257,
680 WINED3DTS_WORLD2 = 258,
681 WINED3DTS_WORLD3 = 259,
682 WINED3DTS_FORCE_DWORD = 0x7fffffff
683 } WINED3DTRANSFORMSTATETYPE;
684 cpp_quote("#define WINED3DTS_WORLDMATRIX(index) (WINED3DTRANSFORMSTATETYPE)(index + 256)")
685
686 typedef enum _WINED3DBASISTYPE
687 {
688 WINED3DBASIS_BEZIER = 0,
689 WINED3DBASIS_BSPLINE = 1,
690 WINED3DBASIS_INTERPOLATE = 2,
691 WINED3DBASIS_FORCE_DWORD = 0x7fffffff
692 } WINED3DBASISTYPE;
693
694 typedef enum _WINED3DCUBEMAP_FACES
695 {
696 WINED3DCUBEMAP_FACE_POSITIVE_X = 0,
697 WINED3DCUBEMAP_FACE_NEGATIVE_X = 1,
698 WINED3DCUBEMAP_FACE_POSITIVE_Y = 2,
699 WINED3DCUBEMAP_FACE_NEGATIVE_Y = 3,
700 WINED3DCUBEMAP_FACE_POSITIVE_Z = 4,
701 WINED3DCUBEMAP_FACE_NEGATIVE_Z = 5,
702 WINED3DCUBEMAP_FACE_FORCE_DWORD = 0xffffffff
703 } WINED3DCUBEMAP_FACES;
704
705 typedef enum _WINED3DTEXTUREFILTERTYPE
706 {
707 WINED3DTEXF_NONE = 0,
708 WINED3DTEXF_POINT = 1,
709 WINED3DTEXF_LINEAR = 2,
710 WINED3DTEXF_ANISOTROPIC = 3,
711 WINED3DTEXF_FLATCUBIC = 4,
712 WINED3DTEXF_GAUSSIANCUBIC = 5,
713 WINED3DTEXF_PYRAMIDALQUAD = 6,
714 WINED3DTEXF_GAUSSIANQUAD = 7,
715 WINED3DTEXF_FORCE_DWORD = 0x7fffffff
716 } WINED3DTEXTUREFILTERTYPE;
717
718 typedef enum _WINED3DRESOURCETYPE
719 {
720 WINED3DRTYPE_SURFACE = 1,
721 WINED3DRTYPE_VOLUME = 2,
722 WINED3DRTYPE_TEXTURE = 3,
723 WINED3DRTYPE_VOLUMETEXTURE = 4,
724 WINED3DRTYPE_CUBETEXTURE = 5,
725 WINED3DRTYPE_BUFFER = 6,
726 WINED3DRTYPE_FORCE_DWORD = 0x7fffffff
727 } WINED3DRESOURCETYPE;
728 const UINT WINED3DRTYPECOUNT = WINED3DRTYPE_BUFFER + 1;
729
730 typedef enum _WINED3DPOOL
731 {
732 WINED3DPOOL_DEFAULT = 0,
733 WINED3DPOOL_MANAGED = 1,
734 WINED3DPOOL_SYSTEMMEM = 2,
735 WINED3DPOOL_SCRATCH = 3,
736 WINED3DPOOL_FORCE_DWORD = 0x7fffffff
737 } WINED3DPOOL;
738
739 typedef enum _WINED3DQUERYTYPE
740 {
741 WINED3DQUERYTYPE_VCACHE = 4,
742 WINED3DQUERYTYPE_RESOURCEMANAGER = 5,
743 WINED3DQUERYTYPE_VERTEXSTATS = 6,
744 WINED3DQUERYTYPE_EVENT = 8,
745 WINED3DQUERYTYPE_OCCLUSION = 9,
746 WINED3DQUERYTYPE_TIMESTAMP = 10,
747 WINED3DQUERYTYPE_TIMESTAMPDISJOINT = 11,
748 WINED3DQUERYTYPE_TIMESTAMPFREQ = 12,
749 WINED3DQUERYTYPE_PIPELINETIMINGS = 13,
750 WINED3DQUERYTYPE_INTERFACETIMINGS = 14,
751 WINED3DQUERYTYPE_VERTEXTIMINGS = 15,
752 WINED3DQUERYTYPE_PIXELTIMINGS = 16,
753 WINED3DQUERYTYPE_BANDWIDTHTIMINGS = 17,
754 WINED3DQUERYTYPE_CACHEUTILIZATION = 18
755 } WINED3DQUERYTYPE;
756
757 const UINT WINED3DISSUE_BEGIN = (1 << 1);
758 const UINT WINED3DISSUE_END = (1 << 0);
759 const UINT WINED3DGETDATA_FLUSH = (1 << 0);
760
761 typedef enum _WINED3DSTATEBLOCKTYPE
762 {
763 WINED3DSBT_INIT = 0,
764 WINED3DSBT_ALL = 1,
765 WINED3DSBT_PIXELSTATE = 2,
766 WINED3DSBT_VERTEXSTATE = 3,
767 WINED3DSBT_RECORDED = 4, /* WineD3D private */
768 WINED3DSBT_FORCE_DWORD = 0xffffffff
769 } WINED3DSTATEBLOCKTYPE;
770
771 typedef enum _WINED3DDECLMETHOD
772 {
773 WINED3DDECLMETHOD_DEFAULT = 0,
774 WINED3DDECLMETHOD_PARTIALU = 1,
775 WINED3DDECLMETHOD_PARTIALV = 2,
776 WINED3DDECLMETHOD_CROSSUV = 3,
777 WINED3DDECLMETHOD_UV = 4,
778 WINED3DDECLMETHOD_LOOKUP = 5,
779 WINED3DDECLMETHOD_LOOKUPPRESAMPLED = 6
780 } WINED3DDECLMETHOD;
781
782 typedef enum _WINED3DDECLUSAGE
783 {
784 WINED3DDECLUSAGE_POSITION = 0,
785 WINED3DDECLUSAGE_BLENDWEIGHT = 1,
786 WINED3DDECLUSAGE_BLENDINDICES = 2,
787 WINED3DDECLUSAGE_NORMAL = 3,
788 WINED3DDECLUSAGE_PSIZE = 4,
789 WINED3DDECLUSAGE_TEXCOORD = 5,
790 WINED3DDECLUSAGE_TANGENT = 6,
791 WINED3DDECLUSAGE_BINORMAL = 7,
792 WINED3DDECLUSAGE_TESSFACTOR = 8,
793 WINED3DDECLUSAGE_POSITIONT = 9,
794 WINED3DDECLUSAGE_COLOR = 10,
795 WINED3DDECLUSAGE_FOG = 11,
796 WINED3DDECLUSAGE_DEPTH = 12,
797 WINED3DDECLUSAGE_SAMPLE = 13
798 } WINED3DDECLUSAGE;
799
800 typedef enum _WINED3DSURFTYPE
801 {
802 SURFACE_UNKNOWN = 0, /* Default / Unknown surface type */
803 SURFACE_OPENGL, /* OpenGL surface: Renders using libGL, needed for 3D */
804 SURFACE_GDI, /* User surface. No 3D, DirectDraw rendering with GDI */
805 } WINED3DSURFTYPE;
806
807 enum wined3d_sysval_semantic
808 {
809 WINED3D_SV_DEPTH = 0xffffffff,
810 WINED3D_SV_TARGET0 = 0,
811 WINED3D_SV_TARGET1 = 1,
812 WINED3D_SV_TARGET2 = 2,
813 WINED3D_SV_TARGET3 = 3,
814 WINED3D_SV_TARGET4 = 4,
815 WINED3D_SV_TARGET5 = 5,
816 WINED3D_SV_TARGET6 = 6,
817 WINED3D_SV_TARGET7 = 7,
818 };
819
820 const UINT WINED3DCOLORWRITEENABLE_RED = (1<<0);
821 const UINT WINED3DCOLORWRITEENABLE_GREEN = (1<<1);
822 const UINT WINED3DCOLORWRITEENABLE_BLUE = (1<<2);
823 const UINT WINED3DCOLORWRITEENABLE_ALPHA = (1<<3);
824
825 const UINT WINED3DADAPTER_DEFAULT = 0;
826 const UINT WINED3DENUM_NO_WHQL_LEVEL = 2;
827 const UINT WINED3DPRESENT_BACK_BUFFER_MAX = 3;
828
829 const UINT WINED3DTSS_TCI_PASSTHRU = 0x00000;
830 const UINT WINED3DTSS_TCI_CAMERASPACENORMAL = 0x10000;
831 const UINT WINED3DTSS_TCI_CAMERASPACEPOSITION = 0x20000;
832 const UINT WINED3DTSS_TCI_CAMERASPACEREFLECTIONVECTOR = 0x30000;
833 const UINT WINED3DTSS_TCI_SPHEREMAP = 0x40000;
834
835 const UINT WINED3DTA_SELECTMASK = 0x0000000f;
836 const UINT WINED3DTA_DIFFUSE = 0x00000000;
837 const UINT WINED3DTA_CURRENT = 0x00000001;
838 const UINT WINED3DTA_TEXTURE = 0x00000002;
839 const UINT WINED3DTA_TFACTOR = 0x00000003;
840 const UINT WINED3DTA_SPECULAR = 0x00000004;
841 const UINT WINED3DTA_TEMP = 0x00000005;
842 const UINT WINED3DTA_CONSTANT = 0x00000006;
843 const UINT WINED3DTA_COMPLEMENT = 0x00000010;
844 const UINT WINED3DTA_ALPHAREPLICATE = 0x00000020;
845
846 const UINT WINED3DPRESENTFLAG_LOCKABLE_BACKBUFFER = 0x00000001;
847 const UINT WINED3DPRESENTFLAG_DISCARD_DEPTHSTENCIL = 0x00000002;
848 const UINT WINED3DPRESENTFLAG_DEVICECLIP = 0x00000004;
849 const UINT WINED3DPRESENTFLAG_VIDEO = 0x00000010;
850 const UINT WINED3DPRESENTFLAG_NOAUTOROTATE = 0x00000020;
851 const UINT WINED3DPRESENTFLAG_UNPRUNEDMODE = 0x00000040;
852
853 const UINT WINED3DDP_MAXTEXCOORD = 8;
854
855 const UINT WINED3DUSAGE_RENDERTARGET = 0x00000001;
856 const UINT WINED3DUSAGE_DEPTHSTENCIL = 0x00000002;
857 const UINT WINED3DUSAGE_WRITEONLY = 0x00000008;
858 const UINT WINED3DUSAGE_SOFTWAREPROCESSING = 0x00000010;
859 const UINT WINED3DUSAGE_DONOTCLIP = 0x00000020;
860 const UINT WINED3DUSAGE_POINTS = 0x00000040;
861 const UINT WINED3DUSAGE_RTPATCHES = 0x00000080;
862 const UINT WINED3DUSAGE_NPATCHES = 0x00000100;
863 const UINT WINED3DUSAGE_DYNAMIC = 0x00000200;
864 const UINT WINED3DUSAGE_AUTOGENMIPMAP = 0x00000400;
865 const UINT WINED3DUSAGE_DMAP = 0x00004000;
866 const UINT WINED3DUSAGE_MASK = 0x00004fff;
867 const UINT WINED3DUSAGE_STATICDECL = 0x40000000;
868 const UINT WINED3DUSAGE_OVERLAY = 0x80000000;
869
870 const UINT WINED3DUSAGE_QUERY_LEGACYBUMPMAP = 0x00008000;
871 const UINT WINED3DUSAGE_QUERY_FILTER = 0x00020000;
872 const UINT WINED3DUSAGE_QUERY_POSTPIXELSHADER_BLENDING = 0x00080000;
873 const UINT WINED3DUSAGE_QUERY_SRGBREAD = 0x00010000;
874 const UINT WINED3DUSAGE_QUERY_SRGBWRITE = 0x00040000;
875 const UINT WINED3DUSAGE_QUERY_VERTEXTEXTURE = 0x00100000;
876 const UINT WINED3DUSAGE_QUERY_WRAPANDMIP = 0x00200000;
877 const UINT WINED3DUSAGE_QUERY_MASK = 0x003f8000;
878
879 const UINT WINED3DLOCK_READONLY = 0x0010;
880 const UINT WINED3DLOCK_NOSYSLOCK = 0x0800;
881 const UINT WINED3DLOCK_NOOVERWRITE = 0x1000;
882 const UINT WINED3DLOCK_DISCARD = 0x2000;
883 const UINT WINED3DLOCK_DONOTWAIT = 0x4000;
884 const UINT WINED3DLOCK_NO_DIRTY_UPDATE = 0x8000;
885
886 const UINT WINED3DPRESENT_RATE_DEFAULT = 0x000000000;
887
888 const UINT WINED3DPRESENT_INTERVAL_DEFAULT = 0x00000000;
889 const UINT WINED3DPRESENT_INTERVAL_ONE = 0x00000001;
890 const UINT WINED3DPRESENT_INTERVAL_TWO = 0x00000002;
891 const UINT WINED3DPRESENT_INTERVAL_THREE = 0x00000004;
892 const UINT WINED3DPRESENT_INTERVAL_FOUR = 0x00000008;
893 const UINT WINED3DPRESENT_INTERVAL_IMMEDIATE = 0x80000000;
894
895 const UINT WINED3DMAXUSERCLIPPLANES = 32;
896 const UINT WINED3DCLIPPLANE0 = (1 << 0);
897 const UINT WINED3DCLIPPLANE1 = (1 << 1);
898 const UINT WINED3DCLIPPLANE2 = (1 << 2);
899 const UINT WINED3DCLIPPLANE3 = (1 << 3);
900 const UINT WINED3DCLIPPLANE4 = (1 << 4);
901 const UINT WINED3DCLIPPLANE5 = (1 << 5);
902
903 /* FVF (Flexible Vertex Format) codes */
904 const UINT WINED3DFVF_RESERVED0 = 0x0001;
905 const UINT WINED3DFVF_POSITION_MASK = 0x400e;
906 const UINT WINED3DFVF_XYZ = 0x0002;
907 const UINT WINED3DFVF_XYZRHW = 0x0004;
908 const UINT WINED3DFVF_XYZB1 = 0x0006;
909 const UINT WINED3DFVF_XYZB2 = 0x0008;
910 const UINT WINED3DFVF_XYZB3 = 0x000a;
911 const UINT WINED3DFVF_XYZB4 = 0x000c;
912 const UINT WINED3DFVF_XYZB5 = 0x000e;
913 const UINT WINED3DFVF_XYZW = 0x4002;
914 const UINT WINED3DFVF_NORMAL = 0x0010;
915 const UINT WINED3DFVF_PSIZE = 0x0020;
916 const UINT WINED3DFVF_DIFFUSE = 0x0040;
917 const UINT WINED3DFVF_SPECULAR = 0x0080;
918 const UINT WINED3DFVF_TEXCOUNT_MASK = 0x0f00;
919 const UINT WINED3DFVF_TEXCOUNT_SHIFT = 8;
920 const UINT WINED3DFVF_TEX0 = 0x0000;
921 const UINT WINED3DFVF_TEX1 = 0x0100;
922 const UINT WINED3DFVF_TEX2 = 0x0200;
923 const UINT WINED3DFVF_TEX3 = 0x0300;
924 const UINT WINED3DFVF_TEX4 = 0x0400;
925 const UINT WINED3DFVF_TEX5 = 0x0500;
926 const UINT WINED3DFVF_TEX6 = 0x0600;
927 const UINT WINED3DFVF_TEX7 = 0x0700;
928 const UINT WINED3DFVF_TEX8 = 0x0800;
929 const UINT WINED3DFVF_LASTBETA_UBYTE4 = 0x1000;
930 const UINT WINED3DFVF_LASTBETA_D3DCOLOR = 0x8000;
931 const UINT WINED3DFVF_RESERVED2 = 0x6000;
932
933 const UINT WINED3DFVF_TEXTUREFORMAT1 = 3;
934 const UINT WINED3DFVF_TEXTUREFORMAT2 = 0;
935 const UINT WINED3DFVF_TEXTUREFORMAT3 = 1;
936 const UINT WINED3DFVF_TEXTUREFORMAT4 = 2;
937 cpp_quote("#define WINED3DFVF_TEXCOORDSIZE1(CoordIndex) (WINED3DFVF_TEXTUREFORMAT1 << (CoordIndex*2 + 16))")
938 cpp_quote("#define WINED3DFVF_TEXCOORDSIZE2(CoordIndex) (WINED3DFVF_TEXTUREFORMAT2)")
939 cpp_quote("#define WINED3DFVF_TEXCOORDSIZE3(CoordIndex) (WINED3DFVF_TEXTUREFORMAT3 << (CoordIndex*2 + 16))")
940 cpp_quote("#define WINED3DFVF_TEXCOORDSIZE4(CoordIndex) (WINED3DFVF_TEXTUREFORMAT4 << (CoordIndex*2 + 16))")
941
942 /* Clear flags */
943 const UINT WINED3DCLEAR_TARGET = 0x00000001;
944 const UINT WINED3DCLEAR_ZBUFFER = 0x00000002;
945 const UINT WINED3DCLEAR_STENCIL = 0x00000004;
946
947 /* Stream source flags */
948 const UINT WINED3DSTREAMSOURCE_INDEXEDDATA = (1 << 30);
949 const UINT WINED3DSTREAMSOURCE_INSTANCEDATA = (2 << 30);
950
951 /* SetPrivateData flags */
952 const UINT WINED3DSPD_IUNKNOWN = 0x00000001;
953
954 /* IWineD3D::CreateDevice behaviour flags */
955 const UINT WINED3DCREATE_FPU_PRESERVE = 0x00000002;
956 const UINT WINED3DCREATE_PUREDEVICE = 0x00000010;
957 const UINT WINED3DCREATE_SOFTWARE_VERTEXPROCESSING = 0x00000020;
958 const UINT WINED3DCREATE_HARDWARE_VERTEXPROCESSING = 0x00000040;
959 const UINT WINED3DCREATE_MIXED_VERTEXPROCESSING = 0x00000080;
960 const UINT WINED3DCREATE_DISABLE_DRIVER_MANAGEMENT = 0x00000100;
961 const UINT WINED3DCREATE_ADAPTERGROUP_DEVICE = 0x00000200;
962
963 /* VTF defines */
964 const UINT WINED3DDMAPSAMPLER = 0x100;
965 const UINT WINED3DVERTEXTEXTURESAMPLER0 = (WINED3DDMAPSAMPLER + 1);
966 const UINT WINED3DVERTEXTEXTURESAMPLER1 = (WINED3DDMAPSAMPLER + 2);
967 const UINT WINED3DVERTEXTEXTURESAMPLER2 = (WINED3DDMAPSAMPLER + 3);
968 const UINT WINED3DVERTEXTEXTURESAMPLER3 = (WINED3DDMAPSAMPLER + 4);
969
970 const UINT WINED3DCAPS3_ALPHA_FULLSCREEN_FLIP_OR_DISCARD = 0x00000020;
971 const UINT WINED3DCAPS3_LINEAR_TO_SRGB_PRESENTATION = 0x00000080;
972 const UINT WINED3DCAPS3_COPY_TO_VIDMEM = 0x00000100;
973 const UINT WINED3DCAPS3_COPY_TO_SYSTEMMEM = 0x00000200;
974 const UINT WINED3DCAPS3_RESERVED = 0x8000001f;
975
976 const UINT WINED3DDEVCAPS2_STREAMOFFSET = 0x00000001;
977 const UINT WINED3DDEVCAPS2_DMAPNPATCH = 0x00000002;
978 const UINT WINED3DDEVCAPS2_ADAPTIVETESSRTPATCH = 0x00000004;
979 const UINT WINED3DDEVCAPS2_ADAPTIVETESSNPATCH = 0x00000008;
980 const UINT WINED3DDEVCAPS2_CAN_STRETCHRECT_FROM_TEXTURES = 0x00000010;
981 const UINT WINED3DDEVCAPS2_PRESAMPLEDDMAPNPATCH = 0x00000020;
982 const UINT WINED3DDEVCAPS2_VERTEXELEMENTSCANSHARESTREAMOFFSET = 0x00000040;
983
984 const UINT WINED3DDTCAPS_UBYTE4 = 0x00000001;
985 const UINT WINED3DDTCAPS_UBYTE4N = 0x00000002;
986 const UINT WINED3DDTCAPS_SHORT2N = 0x00000004;
987 const UINT WINED3DDTCAPS_SHORT4N = 0x00000008;
988 const UINT WINED3DDTCAPS_USHORT2N = 0x00000010;
989 const UINT WINED3DDTCAPS_USHORT4N = 0x00000020;
990 const UINT WINED3DDTCAPS_UDEC3 = 0x00000040;
991 const UINT WINED3DDTCAPS_DEC3N = 0x00000080;
992 const UINT WINED3DDTCAPS_FLOAT16_2 = 0x00000100;
993 const UINT WINED3DDTCAPS_FLOAT16_4 = 0x00000200;
994
995 const UINT WINED3DFVFCAPS_TEXCOORDCOUNTMASK = 0x0000ffff;
996 const UINT WINED3DFVFCAPS_DONOTSTRIPELEMENTS = 0x00080000;
997 const UINT WINED3DFVFCAPS_PSIZE = 0x00100000;
998
999 const UINT WINED3DLINECAPS_TEXTURE = 0x00000001;
1000 const UINT WINED3DLINECAPS_ZTEST = 0x00000002;
1001 const UINT WINED3DLINECAPS_BLEND = 0x00000004;
1002 const UINT WINED3DLINECAPS_ALPHACMP = 0x00000008;
1003 const UINT WINED3DLINECAPS_FOG = 0x00000010;
1004 const UINT WINED3DLINECAPS_ANTIALIAS = 0x00000020;
1005
1006 const UINT WINED3DMAX30SHADERINSTRUCTIONS = 32768;
1007 const UINT WINED3DMIN30SHADERINSTRUCTIONS = 512;
1008
1009 const UINT WINED3DPBLENDCAPS_ZERO = 0x00000001;
1010 const UINT WINED3DPBLENDCAPS_ONE = 0x00000002;
1011 const UINT WINED3DPBLENDCAPS_SRCCOLOR = 0x00000004;
1012 const UINT WINED3DPBLENDCAPS_INVSRCCOLOR = 0x00000008;
1013 const UINT WINED3DPBLENDCAPS_SRCALPHA = 0x00000010;
1014 const UINT WINED3DPBLENDCAPS_INVSRCALPHA = 0x00000020;
1015 const UINT WINED3DPBLENDCAPS_DESTALPHA = 0x00000040;
1016 const UINT WINED3DPBLENDCAPS_INVDESTALPHA = 0x00000080;
1017 const UINT WINED3DPBLENDCAPS_DESTCOLOR = 0x00000100;
1018 const UINT WINED3DPBLENDCAPS_INVDESTCOLOR = 0x00000200;
1019 const UINT WINED3DPBLENDCAPS_SRCALPHASAT = 0x00000400;
1020 const UINT WINED3DPBLENDCAPS_BOTHSRCALPHA = 0x00000800;
1021 const UINT WINED3DPBLENDCAPS_BOTHINVSRCALPHA = 0x00001000;
1022 const UINT WINED3DPBLENDCAPS_BLENDFACTOR = 0x00002000;
1023
1024 const UINT WINED3DPCMPCAPS_NEVER = 0x00000001;
1025 const UINT WINED3DPCMPCAPS_LESS = 0x00000002;
1026 const UINT WINED3DPCMPCAPS_EQUAL = 0x00000004;
1027 const UINT WINED3DPCMPCAPS_LESSEQUAL = 0x00000008;
1028 const UINT WINED3DPCMPCAPS_GREATER = 0x00000010;
1029 const UINT WINED3DPCMPCAPS_NOTEQUAL = 0x00000020;
1030 const UINT WINED3DPCMPCAPS_GREATEREQUAL = 0x00000040;
1031 const UINT WINED3DPCMPCAPS_ALWAYS = 0x00000080;
1032
1033 const UINT WINED3DPMISCCAPS_MASKZ = 0x00000002;
1034 const UINT WINED3DPMISCCAPS_LINEPATTERNREP = 0x00000004;
1035 const UINT WINED3DPMISCCAPS_CULLNONE = 0x00000010;
1036 const UINT WINED3DPMISCCAPS_CULLCW = 0x00000020;
1037 const UINT WINED3DPMISCCAPS_CULLCCW = 0x00000040;
1038 const UINT WINED3DPMISCCAPS_COLORWRITEENABLE = 0x00000080;
1039 const UINT WINED3DPMISCCAPS_CLIPPLANESCALEDPOINTS = 0x00000100;
1040 const UINT WINED3DPMISCCAPS_CLIPTLVERTS = 0x00000200;
1041 const UINT WINED3DPMISCCAPS_TSSARGTEMP = 0x00000400;
1042 const UINT WINED3DPMISCCAPS_BLENDOP = 0x00000800;
1043 const UINT WINED3DPMISCCAPS_NULLREFERENCE = 0x00001000;
1044 const UINT WINED3DPMISCCAPS_INDEPENDENTWRITEMASKS = 0x00004000;
1045 const UINT WINED3DPMISCCAPS_PERSTAGECONSTANT = 0x00008000;
1046 const UINT WINED3DPMISCCAPS_FOGANDSPECULARALPHA = 0x00010000;
1047 const UINT WINED3DPMISCCAPS_SEPARATEALPHABLEND = 0x00020000;
1048 const UINT WINED3DPMISCCAPS_MRTINDEPENDENTBITDEPTHS = 0x00040000;
1049 const UINT WINED3DPMISCCAPS_MRTPOSTPIXELSHADERBLENDING = 0x00080000;
1050 const UINT WINED3DPMISCCAPS_FOGVERTEXCLAMPED = 0x00100000;
1051
1052 const UINT WINED3DPS20_MAX_DYNAMICFLOWCONTROLDEPTH = 24;
1053 const UINT WINED3DPS20_MIN_DYNAMICFLOWCONTROLDEPTH = 0;
1054 const UINT WINED3DPS20_MAX_NUMTEMPS = 32;
1055 const UINT WINED3DPS20_MIN_NUMTEMPS = 12;
1056 const UINT WINED3DPS20_MAX_STATICFLOWCONTROLDEPTH = 4;
1057 const UINT WINED3DPS20_MIN_STATICFLOWCONTROLDEPTH = 0;
1058 const UINT WINED3DPS20_MAX_NUMINSTRUCTIONSLOTS = 512;
1059 const UINT WINED3DPS20_MIN_NUMINSTRUCTIONSLOTS = 96;
1060
1061 const UINT WINED3DPS20CAPS_ARBITRARYSWIZZLE = 0x00000001;
1062 const UINT WINED3DPS20CAPS_GRADIENTINSTRUCTIONS = 0x00000002;
1063 const UINT WINED3DPS20CAPS_PREDICATION = 0x00000004;
1064 const UINT WINED3DPS20CAPS_NODEPENDENTREADLIMIT = 0x00000008;
1065 const UINT WINED3DPS20CAPS_NOTEXINSTRUCTIONLIMIT = 0x00000010;
1066
1067 const UINT WINED3DPTADDRESSCAPS_WRAP = 0x00000001;
1068 const UINT WINED3DPTADDRESSCAPS_MIRROR = 0x00000002;
1069 const UINT WINED3DPTADDRESSCAPS_CLAMP = 0x00000004;
1070 const UINT WINED3DPTADDRESSCAPS_BORDER = 0x00000008;
1071 const UINT WINED3DPTADDRESSCAPS_INDEPENDENTUV = 0x00000010;
1072 const UINT WINED3DPTADDRESSCAPS_MIRRORONCE = 0x00000020;
1073
1074 const UINT WINED3DSTENCILCAPS_KEEP = 0x00000001;
1075 const UINT WINED3DSTENCILCAPS_ZERO = 0x00000002;
1076 const UINT WINED3DSTENCILCAPS_REPLACE = 0x00000004;
1077 const UINT WINED3DSTENCILCAPS_INCRSAT = 0x00000008;
1078 const UINT WINED3DSTENCILCAPS_DECRSAT = 0x00000010;
1079 const UINT WINED3DSTENCILCAPS_INVERT = 0x00000020;
1080 const UINT WINED3DSTENCILCAPS_INCR = 0x00000040;
1081 const UINT WINED3DSTENCILCAPS_DECR = 0x00000080;
1082 const UINT WINED3DSTENCILCAPS_TWOSIDED = 0x00000100;
1083
1084 const UINT WINED3DTEXOPCAPS_DISABLE = 0x00000001;
1085 const UINT WINED3DTEXOPCAPS_SELECTARG1 = 0x00000002;
1086 const UINT WINED3DTEXOPCAPS_SELECTARG2 = 0x00000004;
1087 const UINT WINED3DTEXOPCAPS_MODULATE = 0x00000008;
1088 const UINT WINED3DTEXOPCAPS_MODULATE2X = 0x00000010;
1089 const UINT WINED3DTEXOPCAPS_MODULATE4X = 0x00000020;
1090 const UINT WINED3DTEXOPCAPS_ADD = 0x00000040;
1091 const UINT WINED3DTEXOPCAPS_ADDSIGNED = 0x00000080;
1092 const UINT WINED3DTEXOPCAPS_ADDSIGNED2X = 0x00000100;
1093 const UINT WINED3DTEXOPCAPS_SUBTRACT = 0x00000200;
1094 const UINT WINED3DTEXOPCAPS_ADDSMOOTH = 0x00000400;
1095 const UINT WINED3DTEXOPCAPS_BLENDDIFFUSEALPHA = 0x00000800;
1096 const UINT WINED3DTEXOPCAPS_BLENDTEXTUREALPHA = 0x00001000;
1097 const UINT WINED3DTEXOPCAPS_BLENDFACTORALPHA = 0x00002000;
1098 const UINT WINED3DTEXOPCAPS_BLENDTEXTUREALPHAPM = 0x00004000;
1099 const UINT WINED3DTEXOPCAPS_BLENDCURRENTALPHA = 0x00008000;
1100 const UINT WINED3DTEXOPCAPS_PREMODULATE = 0x00010000;
1101 const UINT WINED3DTEXOPCAPS_MODULATEALPHA_ADDCOLOR = 0x00020000;
1102 const UINT WINED3DTEXOPCAPS_MODULATECOLOR_ADDALPHA = 0x00040000;
1103 const UINT WINED3DTEXOPCAPS_MODULATEINVALPHA_ADDCOLOR = 0x00080000;
1104 const UINT WINED3DTEXOPCAPS_MODULATEINVCOLOR_ADDALPHA = 0x00100000;
1105 const UINT WINED3DTEXOPCAPS_BUMPENVMAP = 0x00200000;
1106 const UINT WINED3DTEXOPCAPS_BUMPENVMAPLUMINANCE = 0x00400000;
1107 const UINT WINED3DTEXOPCAPS_DOTPRODUCT3 = 0x00800000;
1108 const UINT WINED3DTEXOPCAPS_MULTIPLYADD = 0x01000000;
1109 const UINT WINED3DTEXOPCAPS_LERP = 0x02000000;
1110
1111 const UINT WINED3DVS20_MAX_DYNAMICFLOWCONTROLDEPTH = 24;
1112 const UINT WINED3DVS20_MIN_DYNAMICFLOWCONTROLDEPTH = 0;
1113 const UINT WINED3DVS20_MAX_NUMTEMPS = 32;
1114 const UINT WINED3DVS20_MIN_NUMTEMPS = 12;
1115 const UINT WINED3DVS20_MAX_STATICFLOWCONTROLDEPTH = 4;
1116 const UINT WINED3DVS20_MIN_STATICFLOWCONTROLDEPTH = 1;
1117
1118 const UINT WINED3DVS20CAPS_PREDICATION = 0x00000001;
1119
1120 const UINT WINED3DCAPS2_NO2DDURING3DSCENE = 0x00000002;
1121 const UINT WINED3DCAPS2_FULLSCREENGAMMA = 0x00020000;
1122 const UINT WINED3DCAPS2_CANRENDERWINDOWED = 0x00080000;
1123 const UINT WINED3DCAPS2_CANCALIBRATEGAMMA = 0x00100000;
1124 const UINT WINED3DCAPS2_RESERVED = 0x02000000;
1125 const UINT WINED3DCAPS2_CANMANAGERESOURCE = 0x10000000;
1126 const UINT WINED3DCAPS2_DYNAMICTEXTURES = 0x20000000;
1127 const UINT WINED3DCAPS2_CANAUTOGENMIPMAP = 0x40000000;
1128
1129 const UINT WINED3DPRASTERCAPS_DITHER = 0x00000001;
1130 const UINT WINED3DPRASTERCAPS_ROP2 = 0x00000002;
1131 const UINT WINED3DPRASTERCAPS_XOR = 0x00000004;
1132 const UINT WINED3DPRASTERCAPS_PAT = 0x00000008;
1133 const UINT WINED3DPRASTERCAPS_ZTEST = 0x00000010;
1134 const UINT WINED3DPRASTERCAPS_SUBPIXEL = 0x00000020;
1135 const UINT WINED3DPRASTERCAPS_SUBPIXELX = 0x00000040;
1136 const UINT WINED3DPRASTERCAPS_FOGVERTEX = 0x00000080;
1137 const UINT WINED3DPRASTERCAPS_FOGTABLE = 0x00000100;
1138 const UINT WINED3DPRASTERCAPS_STIPPLE = 0x00000200;
1139 const UINT WINED3DPRASTERCAPS_ANTIALIASSORTDEPENDENT = 0x00000400;
1140 const UINT WINED3DPRASTERCAPS_ANTIALIASSORTINDEPENDENT = 0x00000800;
1141 const UINT WINED3DPRASTERCAPS_ANTIALIASEDGES = 0x00001000;
1142 const UINT WINED3DPRASTERCAPS_MIPMAPLODBIAS = 0x00002000;
1143 const UINT WINED3DPRASTERCAPS_ZBIAS = 0x00004000;
1144 const UINT WINED3DPRASTERCAPS_ZBUFFERLESSHSR = 0x00008000;
1145 const UINT WINED3DPRASTERCAPS_FOGRANGE = 0x00010000;
1146 const UINT WINED3DPRASTERCAPS_ANISOTROPY = 0x00020000;
1147 const UINT WINED3DPRASTERCAPS_WBUFFER = 0x00040000;
1148 const UINT WINED3DPRASTERCAPS_TRANSLUCENTSORTINDEPENDENT = 0x00080000;
1149 const UINT WINED3DPRASTERCAPS_WFOG = 0x00100000;
1150 const UINT WINED3DPRASTERCAPS_ZFOG = 0x00200000;
1151 const UINT WINED3DPRASTERCAPS_COLORPERSPECTIVE = 0x00400000;
1152 const UINT WINED3DPRASTERCAPS_SCISSORTEST = 0x01000000;
1153 const UINT WINED3DPRASTERCAPS_SLOPESCALEDEPTHBIAS = 0x02000000;
1154 const UINT WINED3DPRASTERCAPS_DEPTHBIAS = 0x04000000;
1155 const UINT WINED3DPRASTERCAPS_MULTISAMPLE_TOGGLE = 0x08000000;
1156
1157 const UINT WINED3DPSHADECAPS_COLORFLATMONO = 0x00000001;
1158 const UINT WINED3DPSHADECAPS_COLORFLATRGB = 0x00000002;
1159 const UINT WINED3DPSHADECAPS_COLORGOURAUDMONO = 0x00000004;
1160 const UINT WINED3DPSHADECAPS_COLORGOURAUDRGB = 0x00000008;
1161 const UINT WINED3DPSHADECAPS_COLORPHONGMONO = 0x00000010;
1162 const UINT WINED3DPSHADECAPS_COLORPHONGRGB = 0x00000020;
1163 const UINT WINED3DPSHADECAPS_SPECULARFLATMONO = 0x00000040;
1164 const UINT WINED3DPSHADECAPS_SPECULARFLATRGB = 0x00000080;
1165 const UINT WINED3DPSHADECAPS_SPECULARGOURAUDMONO = 0x00000100;
1166 const UINT WINED3DPSHADECAPS_SPECULARGOURAUDRGB = 0x00000200;
1167 const UINT WINED3DPSHADECAPS_SPECULARPHONGMONO = 0x00000400;
1168 const UINT WINED3DPSHADECAPS_SPECULARPHONGRGB = 0x00000800;
1169 const UINT WINED3DPSHADECAPS_ALPHAFLATBLEND = 0x00001000;
1170 const UINT WINED3DPSHADECAPS_ALPHAFLATSTIPPLED = 0x00002000;
1171 const UINT WINED3DPSHADECAPS_ALPHAGOURAUDBLEND = 0x00004000;
1172 const UINT WINED3DPSHADECAPS_ALPHAGOURAUDSTIPPLED = 0x00008000;
1173 const UINT WINED3DPSHADECAPS_ALPHAPHONGBLEND = 0x00010000;
1174 const UINT WINED3DPSHADECAPS_ALPHAPHONGSTIPPLED = 0x00020000;
1175 const UINT WINED3DPSHADECAPS_FOGFLAT = 0x00040000;
1176 const UINT WINED3DPSHADECAPS_FOGGOURAUD = 0x00080000;
1177 const UINT WINED3DPSHADECAPS_FOGPHONG = 0x00100000;
1178
1179 const UINT WINED3DPTEXTURECAPS_PERSPECTIVE = 0x00000001;
1180 const UINT WINED3DPTEXTURECAPS_POW2 = 0x00000002;
1181 const UINT WINED3DPTEXTURECAPS_ALPHA = 0x00000004;
1182 const UINT WINED3DPTEXTURECAPS_TRANSPARENCY = 0x00000008;
1183 const UINT WINED3DPTEXTURECAPS_BORDER = 0x00000010;
1184 const UINT WINED3DPTEXTURECAPS_SQUAREONLY = 0x00000020;
1185 const UINT WINED3DPTEXTURECAPS_TEXREPEATNOTSCALEDBYSIZE = 0x00000040;
1186 const UINT WINED3DPTEXTURECAPS_ALPHAPALETTE = 0x00000080;
1187 const UINT WINED3DPTEXTURECAPS_NONPOW2CONDITIONAL = 0x00000100;
1188 const UINT WINED3DPTEXTURECAPS_PROJECTED = 0x00000400;
1189 const UINT WINED3DPTEXTURECAPS_CUBEMAP = 0x00000800;
1190 const UINT WINED3DPTEXTURECAPS_COLORKEYBLEND = 0x00001000;
1191 const UINT WINED3DPTEXTURECAPS_VOLUMEMAP = 0x00002000;
1192 const UINT WINED3DPTEXTURECAPS_MIPMAP = 0x00004000;
1193 const UINT WINED3DPTEXTURECAPS_MIPVOLUMEMAP = 0x00008000;
1194 const UINT WINED3DPTEXTURECAPS_MIPCUBEMAP = 0x00010000;
1195 const UINT WINED3DPTEXTURECAPS_CUBEMAP_POW2 = 0x00020000;
1196 const UINT WINED3DPTEXTURECAPS_VOLUMEMAP_POW2 = 0x00040000;
1197 const UINT WINED3DPTEXTURECAPS_NOPROJECTEDBUMPENV = 0x00200000;
1198
1199 const UINT WINED3DPTFILTERCAPS_NEAREST = 0x00000001;
1200 const UINT WINED3DPTFILTERCAPS_LINEAR = 0x00000002;
1201 const UINT WINED3DPTFILTERCAPS_MIPNEAREST = 0x00000004;
1202 const UINT WINED3DPTFILTERCAPS_MIPLINEAR = 0x00000008;
1203 const UINT WINED3DPTFILTERCAPS_LINEARMIPNEAREST = 0x00000010;
1204 const UINT WINED3DPTFILTERCAPS_LINEARMIPLINEAR = 0x00000020;
1205 const UINT WINED3DPTFILTERCAPS_MINFPOINT = 0x00000100;
1206 const UINT WINED3DPTFILTERCAPS_MINFLINEAR = 0x00000200;
1207 const UINT WINED3DPTFILTERCAPS_MINFANISOTROPIC = 0x00000400;
1208 const UINT WINED3DPTFILTERCAPS_MIPFPOINT = 0x00010000;
1209 const UINT WINED3DPTFILTERCAPS_MIPFLINEAR = 0x00020000;
1210 const UINT WINED3DPTFILTERCAPS_MAGFPOINT = 0x01000000;
1211 const UINT WINED3DPTFILTERCAPS_MAGFLINEAR = 0x02000000;
1212 const UINT WINED3DPTFILTERCAPS_MAGFANISOTROPIC = 0x04000000;
1213 const UINT WINED3DPTFILTERCAPS_MAGFPYRAMIDALQUAD = 0x08000000;
1214 const UINT WINED3DPTFILTERCAPS_MAGFGAUSSIANQUAD = 0x10000000;
1215
1216 const UINT WINED3DVTXPCAPS_TEXGEN = 0x00000001;
1217 const UINT WINED3DVTXPCAPS_MATERIALSOURCE7 = 0x00000002;
1218 const UINT WINED3DVTXPCAPS_VERTEXFOG = 0x00000004;
1219 const UINT WINED3DVTXPCAPS_DIRECTIONALLIGHTS = 0x00000008;
1220 const UINT WINED3DVTXPCAPS_POSITIONALLIGHTS = 0x00000010;
1221 const UINT WINED3DVTXPCAPS_LOCALVIEWER = 0x00000020;
1222 const UINT WINED3DVTXPCAPS_TWEENING = 0x00000040;
1223 const UINT WINED3DVTXPCAPS_TEXGEN_SPHEREMAP = 0x00000100;
1224 const UINT WINED3DVTXPCAPS_NO_TEXGEN_NONLOCALVIEWER = 0x00000200;
1225
1226 const UINT WINED3DCURSORCAPS_COLOR = 0x00000001;
1227 const UINT WINED3DCURSORCAPS_LOWRES = 0x00000002;
1228
1229 const UINT WINED3DDEVCAPS_FLOATTLVERTEX = 0x00000001;
1230 const UINT WINED3DDEVCAPS_SORTINCREASINGZ = 0x00000002;
1231 const UINT WINED3DDEVCAPS_SORTDECREASINGZ = 0X00000004;
1232 const UINT WINED3DDEVCAPS_SORTEXACT = 0x00000008;
1233 const UINT WINED3DDEVCAPS_EXECUTESYSTEMMEMORY = 0x00000010;
1234 const UINT WINED3DDEVCAPS_EXECUTEVIDEOMEMORY = 0x00000020;
1235 const UINT WINED3DDEVCAPS_TLVERTEXSYSTEMMEMORY = 0x00000040;
1236 const UINT WINED3DDEVCAPS_TLVERTEXVIDEOMEMORY = 0x00000080;
1237 const UINT WINED3DDEVCAPS_TEXTURESYSTEMMEMORY = 0x00000100;
1238 const UINT WINED3DDEVCAPS_TEXTUREVIDEOMEMORY = 0x00000200;
1239 const UINT WINED3DDEVCAPS_DRAWPRIMTLVERTEX = 0x00000400;
1240 const UINT WINED3DDEVCAPS_CANRENDERAFTERFLIP = 0x00000800;
1241 const UINT WINED3DDEVCAPS_TEXTURENONLOCALVIDMEM = 0x00001000;
1242 const UINT WINED3DDEVCAPS_DRAWPRIMITIVES2 = 0x00002000;
1243 const UINT WINED3DDEVCAPS_SEPARATETEXTUREMEMORIES = 0x00004000;
1244 const UINT WINED3DDEVCAPS_DRAWPRIMITIVES2EX = 0x00008000;
1245 const UINT WINED3DDEVCAPS_HWTRANSFORMANDLIGHT = 0x00010000;
1246 const UINT WINED3DDEVCAPS_CANBLTSYSTONONLOCAL = 0x00020000;
1247 const UINT WINED3DDEVCAPS_HWRASTERIZATION = 0x00080000;
1248 const UINT WINED3DDEVCAPS_PUREDEVICE = 0x00100000;
1249 const UINT WINED3DDEVCAPS_QUINTICRTPATCHES = 0x00200000;
1250 const UINT WINED3DDEVCAPS_RTPATCHES = 0x00400000;
1251 const UINT WINED3DDEVCAPS_RTPATCHHANDLEZERO = 0x00800000;
1252 const UINT WINED3DDEVCAPS_NPATCHES = 0x01000000;
1253
1254 /* dwDDFX */
1255 /* arithmetic stretching along y axis */
1256 const UINT WINEDDBLTFX_ARITHSTRETCHY = 0x00000001;
1257 /* mirror on y axis */
1258 const UINT WINEDDBLTFX_MIRRORLEFTRIGHT = 0x00000002;
1259 /* mirror on x axis */
1260 const UINT WINEDDBLTFX_MIRRORUPDOWN = 0x00000004;
1261 /* do not tear */
1262 const UINT WINEDDBLTFX_NOTEARING = 0x00000008;
1263 /* 180 degrees clockwise rotation */
1264 const UINT WINEDDBLTFX_ROTATE180 = 0x00000010;
1265 /* 270 degrees clockwise rotation */
1266 const UINT WINEDDBLTFX_ROTATE270 = 0x00000020;
1267 /* 90 degrees clockwise rotation */
1268 const UINT WINEDDBLTFX_ROTATE90 = 0x00000040;
1269 /* dwZBufferLow and dwZBufferHigh specify limits to the copied Z values */
1270 const UINT WINEDDBLTFX_ZBUFFERRANGE = 0x00000080;
1271 /* add dwZBufferBaseDest to every source z value before compare */
1272 const UINT WINEDDBLTFX_ZBUFFERBASEDEST = 0x00000100;
1273
1274 /* dwFlags for Blt* */
1275 const UINT WINEDDBLT_ALPHADEST = 0x00000001;
1276 const UINT WINEDDBLT_ALPHADESTCONSTOVERRIDE = 0x00000002;
1277 const UINT WINEDDBLT_ALPHADESTNEG = 0x00000004;
1278 const UINT WINEDDBLT_ALPHADESTSURFACEOVERRIDE = 0x00000008;
1279 const UINT WINEDDBLT_ALPHAEDGEBLEND = 0x00000010;
1280 const UINT WINEDDBLT_ALPHASRC = 0x00000020;
1281 const UINT WINEDDBLT_ALPHASRCCONSTOVERRIDE = 0x00000040;
1282 const UINT WINEDDBLT_ALPHASRCNEG = 0x00000080;
1283 const UINT WINEDDBLT_ALPHASRCSURFACEOVERRIDE = 0x00000100;
1284 const UINT WINEDDBLT_ASYNC = 0x00000200;
1285 const UINT WINEDDBLT_COLORFILL = 0x00000400;
1286 const UINT WINEDDBLT_DDFX = 0x00000800;
1287 const UINT WINEDDBLT_DDROPS = 0x00001000;
1288 const UINT WINEDDBLT_KEYDEST = 0x00002000;
1289 const UINT WINEDDBLT_KEYDESTOVERRIDE = 0x00004000;
1290 const UINT WINEDDBLT_KEYSRC = 0x00008000;
1291 const UINT WINEDDBLT_KEYSRCOVERRIDE = 0x00010000;
1292 const UINT WINEDDBLT_ROP = 0x00020000;
1293 const UINT WINEDDBLT_ROTATIONANGLE = 0x00040000;
1294 const UINT WINEDDBLT_ZBUFFER = 0x00080000;
1295 const UINT WINEDDBLT_ZBUFFERDESTCONSTOVERRIDE = 0x00100000;
1296 const UINT WINEDDBLT_ZBUFFERDESTOVERRIDE = 0x00200000;
1297 const UINT WINEDDBLT_ZBUFFERSRCCONSTOVERRIDE = 0x00400000;
1298 const UINT WINEDDBLT_ZBUFFERSRCOVERRIDE = 0x00800000;
1299 const UINT WINEDDBLT_WAIT = 0x01000000;
1300 const UINT WINEDDBLT_DEPTHFILL = 0x02000000;
1301 const UINT WINEDDBLT_DONOTWAIT = 0x08000000;
1302
1303 /* dwTrans for BltFast */
1304 const UINT WINEDDBLTFAST_NOCOLORKEY = 0x00000000;
1305 const UINT WINEDDBLTFAST_SRCCOLORKEY = 0x00000001;
1306 const UINT WINEDDBLTFAST_DESTCOLORKEY = 0x00000002;
1307 const UINT WINEDDBLTFAST_WAIT = 0x00000010;
1308 const UINT WINEDDBLTFAST_DONOTWAIT = 0x00000020;
1309
1310 /* DDSURFACEDESC.dwFlags */
1311 const UINT WINEDDSD_CAPS = 0x00000001;
1312 const UINT WINEDDSD_HEIGHT = 0x00000002;
1313 const UINT WINEDDSD_WIDTH = 0x00000004;
1314 const UINT WINEDDSD_PITCH = 0x00000008;
1315 const UINT WINEDDSD_BACKBUFFERCOUNT = 0x00000020;
1316 const UINT WINEDDSD_ZBUFFERBITDEPTH = 0x00000040;
1317 const UINT WINEDDSD_ALPHABITDEPTH = 0x00000080;
1318 const UINT WINEDDSD_LPSURFACE = 0x00000800;
1319 const UINT WINEDDSD_PIXELFORMAT = 0x00001000;
1320 const UINT WINEDDSD_CKDESTOVERLAY = 0x00002000;
1321 const UINT WINEDDSD_CKDESTBLT = 0x00004000;
1322 const UINT WINEDDSD_CKSRCOVERLAY = 0x00008000;
1323 const UINT WINEDDSD_CKSRCBLT = 0x00010000;
1324 const UINT WINEDDSD_MIPMAPCOUNT = 0x00020000;
1325 const UINT WINEDDSD_REFRESHRATE = 0x00040000;
1326 const UINT WINEDDSD_LINEARSIZE = 0x00080000;
1327 const UINT WINEDDSD_TEXTURESTAGE = 0x00100000;
1328 const UINT WINEDDSD_FVF = 0x00200000;
1329 const UINT WINEDDSD_SRCVBHANDLE = 0x00400000;
1330 const UINT WINEDDSD_ALL = 0x007ff9ee;
1331
1332 /* Set/Get Colour Key Flags */
1333 const UINT WINEDDCKEY_COLORSPACE = 0x00000001; /* Struct is single colour space */
1334 const UINT WINEDDCKEY_DESTBLT = 0x00000002; /* To be used as dest for blt */
1335 const UINT WINEDDCKEY_DESTOVERLAY = 0x00000004; /* To be used as dest for CK overlays */
1336 const UINT WINEDDCKEY_SRCBLT = 0x00000008; /* To be used as src for blt */
1337 const UINT WINEDDCKEY_SRCOVERLAY = 0x00000010; /* To be used as src for CK overlays */
1338
1339 /* dwFlags for GetBltStatus */
1340 const UINT WINEDDGBS_CANBLT = 0x00000001;
1341 const UINT WINEDDGBS_ISBLTDONE = 0x00000002;
1342
1343 /* dwFlags for GetFlipStatus */
1344 const UINT WINEDDGFS_CANFLIP = 0x00000001;
1345 const UINT WINEDDGFS_ISFLIPDONE = 0x00000002;
1346
1347 /* dwFlags for Flip */
1348 const UINT WINEDDFLIP_WAIT = 0x00000001;
1349 const UINT WINEDDFLIP_EVEN = 0x00000002; /* only valid for overlay */
1350 const UINT WINEDDFLIP_ODD = 0x00000004; /* only valid for overlay */
1351 const UINT WINEDDFLIP_NOVSYNC = 0x00000008;
1352 const UINT WINEDDFLIP_STEREO = 0x00000010;
1353 const UINT WINEDDFLIP_DONOTWAIT = 0x00000020;
1354 const UINT WINEDDFLIP_INTERVAL2 = 0x02000000;
1355 const UINT WINEDDFLIP_INTERVAL3 = 0x03000000;
1356 const UINT WINEDDFLIP_INTERVAL4 = 0x04000000;
1357
1358 const UINT WINEDDOVER_ALPHADEST = 0x00000001;
1359 const UINT WINEDDOVER_ALPHADESTCONSTOVERRIDE = 0x00000002;
1360 const UINT WINEDDOVER_ALPHADESTNEG = 0x00000004;
1361 const UINT WINEDDOVER_ALPHADESTSURFACEOVERRIDE = 0x00000008;
1362 const UINT WINEDDOVER_ALPHAEDGEBLEND = 0x00000010;
1363 const UINT WINEDDOVER_ALPHASRC = 0x00000020;
1364 const UINT WINEDDOVER_ALPHASRCCONSTOVERRIDE = 0x00000040;
1365 const UINT WINEDDOVER_ALPHASRCNEG = 0x00000080;
1366 const UINT WINEDDOVER_ALPHASRCSURFACEOVERRIDE = 0x00000100;
1367 const UINT WINEDDOVER_HIDE = 0x00000200;
1368 const UINT WINEDDOVER_KEYDEST = 0x00000400;
1369 const UINT WINEDDOVER_KEYDESTOVERRIDE = 0x00000800;
1370 const UINT WINEDDOVER_KEYSRC = 0x00001000;
1371 const UINT WINEDDOVER_KEYSRCOVERRIDE = 0x00002000;
1372 const UINT WINEDDOVER_SHOW = 0x00004000;
1373 const UINT WINEDDOVER_ADDDIRTYRECT = 0x00008000;
1374 const UINT WINEDDOVER_REFRESHDIRTYRECTS = 0x00010000;
1375 const UINT WINEDDOVER_REFRESHALL = 0x00020000;
1376 const UINT WINEDDOVER_DDFX = 0x00080000;
1377 const UINT WINEDDOVER_AUTOFLIP = 0x00100000;
1378 const UINT WINEDDOVER_BOB = 0x00200000;
1379 const UINT WINEDDOVER_OVERRIDEBOBWEAVE = 0x00400000;
1380 const UINT WINEDDOVER_INTERLEAVED = 0x00800000;
1381
1382 /* DirectDraw Caps */
1383 const UINT WINEDDSCAPS_RESERVED1 = 0x00000001;
1384 const UINT WINEDDSCAPS_ALPHA = 0x00000002;
1385 const UINT WINEDDSCAPS_BACKBUFFER = 0x00000004;
1386 const UINT WINEDDSCAPS_COMPLEX = 0x00000008;
1387 const UINT WINEDDSCAPS_FLIP = 0x00000010;
1388 const UINT WINEDDSCAPS_FRONTBUFFER = 0x00000020;
1389 const UINT WINEDDSCAPS_OFFSCREENPLAIN = 0x00000040;
1390 const UINT WINEDDSCAPS_OVERLAY = 0x00000080;
1391 const UINT WINEDDSCAPS_PALETTE = 0x00000100;
1392 const UINT WINEDDSCAPS_PRIMARYSURFACE = 0x00000200;
1393 const UINT WINEDDSCAPS_PRIMARYSURFACELEFT = 0x00000400;
1394 const UINT WINEDDSCAPS_SYSTEMMEMORY = 0x00000800;
1395 const UINT WINEDDSCAPS_TEXTURE = 0x00001000;
1396 const UINT WINEDDSCAPS_3DDEVICE = 0x00002000;
1397 const UINT WINEDDSCAPS_VIDEOMEMORY = 0x00004000;
1398 const UINT WINEDDSCAPS_VISIBLE = 0x00008000;
1399 const UINT WINEDDSCAPS_WRITEONLY = 0x00010000;
1400 const UINT WINEDDSCAPS_ZBUFFER = 0x00020000;
1401 const UINT WINEDDSCAPS_OWNDC = 0x00040000;
1402 const UINT WINEDDSCAPS_LIVEVIDEO = 0x00080000;
1403 const UINT WINEDDSCAPS_HWCODEC = 0x00100000;
1404 const UINT WINEDDSCAPS_MODEX = 0x00200000;
1405 const UINT WINEDDSCAPS_MIPMAP = 0x00400000;
1406 const UINT WINEDDSCAPS_RESERVED2 = 0x00800000;
1407 const UINT WINEDDSCAPS_ALLOCONLOAD = 0x04000000;
1408 const UINT WINEDDSCAPS_VIDEOPORT = 0x08000000;
1409 const UINT WINEDDSCAPS_LOCALVIDMEM = 0x10000000;
1410 const UINT WINEDDSCAPS_NONLOCALVIDMEM = 0x20000000;
1411 const UINT WINEDDSCAPS_STANDARDVGAMODE = 0x40000000;
1412 const UINT WINEDDSCAPS_OPTIMIZED = 0x80000000;
1413
1414 const UINT WINEDDCKEYCAPS_DESTBLT = 0x00000001;
1415 const UINT WINEDDCKEYCAPS_DESTBLTCLRSPACE = 0x00000002;
1416 const UINT WINEDDCKEYCAPS_DESTBLTCLRSPACEYUV = 0x00000004;
1417 const UINT WINEDDCKEYCAPS_DESTBLTYUV = 0x00000008;
1418 const UINT WINEDDCKEYCAPS_DESTOVERLAY = 0x00000010;
1419 const UINT WINEDDCKEYCAPS_DESTOVERLAYCLRSPACE = 0x00000020;
1420 const UINT WINEDDCKEYCAPS_DESTOVERLAYCLRSPACEYUV = 0x00000040;
1421 const UINT WINEDDCKEYCAPS_DESTOVERLAYONEACTIVE = 0x00000080;
1422 const UINT WINEDDCKEYCAPS_DESTOVERLAYYUV = 0x00000100;
1423 const UINT WINEDDCKEYCAPS_SRCBLT = 0x00000200;
1424 const UINT WINEDDCKEYCAPS_SRCBLTCLRSPACE = 0x00000400;
1425 const UINT WINEDDCKEYCAPS_SRCBLTCLRSPACEYUV = 0x00000800;
1426 const UINT WINEDDCKEYCAPS_SRCBLTYUV = 0x00001000;
1427 const UINT WINEDDCKEYCAPS_SRCOVERLAY = 0x00002000;
1428 const UINT WINEDDCKEYCAPS_SRCOVERLAYCLRSPACE = 0x00004000;
1429 const UINT WINEDDCKEYCAPS_SRCOVERLAYCLRSPACEYUV = 0x00008000;
1430 const UINT WINEDDCKEYCAPS_SRCOVERLAYONEACTIVE = 0x00010000;
1431 const UINT WINEDDCKEYCAPS_SRCOVERLAYYUV = 0x00020000;
1432 const UINT WINEDDCKEYCAPS_NOCOSTOVERLAY = 0x00040000;
1433
1434 const UINT WINEDDFXCAPS_BLTALPHA = 0x00000001;
1435 const UINT WINEDDFXCAPS_OVERLAYALPHA = 0x00000004;
1436 const UINT WINEDDFXCAPS_BLTARITHSTRETCHYN = 0x00000010;
1437 const UINT WINEDDFXCAPS_BLTARITHSTRETCHY = 0x00000020;
1438 const UINT WINEDDFXCAPS_BLTMIRRORLEFTRIGHT = 0x00000040;
1439 const UINT WINEDDFXCAPS_BLTMIRRORUPDOWN = 0x00000080;
1440 const UINT WINEDDFXCAPS_BLTROTATION = 0x00000100;
1441 const UINT WINEDDFXCAPS_BLTROTATION90 = 0x00000200;
1442 const UINT WINEDDFXCAPS_BLTSHRINKX = 0x00000400;
1443 const UINT WINEDDFXCAPS_BLTSHRINKXN = 0x00000800;
1444 const UINT WINEDDFXCAPS_BLTSHRINKY = 0x00001000;
1445 const UINT WINEDDFXCAPS_BLTSHRINKYN = 0x00002000;
1446 const UINT WINEDDFXCAPS_BLTSTRETCHX = 0x00004000;
1447 const UINT WINEDDFXCAPS_BLTSTRETCHXN = 0x00008000;
1448 const UINT WINEDDFXCAPS_BLTSTRETCHY = 0x00010000;
1449 const UINT WINEDDFXCAPS_BLTSTRETCHYN = 0x00020000;
1450 const UINT WINEDDFXCAPS_OVERLAYARITHSTRETCHY = 0x00040000;
1451 const UINT WINEDDFXCAPS_OVERLAYARITHSTRETCHYN = 0x00000008;
1452 const UINT WINEDDFXCAPS_OVERLAYSHRINKX = 0x00080000;
1453 const UINT WINEDDFXCAPS_OVERLAYSHRINKXN = 0x00100000;
1454 const UINT WINEDDFXCAPS_OVERLAYSHRINKY = 0x00200000;
1455 const UINT WINEDDFXCAPS_OVERLAYSHRINKYN = 0x00400000;
1456 const UINT WINEDDFXCAPS_OVERLAYSTRETCHX = 0x00800000;
1457 const UINT WINEDDFXCAPS_OVERLAYSTRETCHXN = 0x01000000;
1458 const UINT WINEDDFXCAPS_OVERLAYSTRETCHY = 0x02000000;
1459 const UINT WINEDDFXCAPS_OVERLAYSTRETCHYN = 0x04000000;
1460 const UINT WINEDDFXCAPS_OVERLAYMIRRORLEFTRIGHT = 0x08000000;
1461 const UINT WINEDDFXCAPS_OVERLAYMIRRORUPDOWN = 0x10000000;
1462
1463 const UINT WINEDDCAPS_3D = 0x00000001;
1464 const UINT WINEDDCAPS_ALIGNBOUNDARYDEST = 0x00000002;
1465 const UINT WINEDDCAPS_ALIGNSIZEDEST = 0x00000004;
1466 const UINT WINEDDCAPS_ALIGNBOUNDARYSRC = 0x00000008;
1467 const UINT WINEDDCAPS_ALIGNSIZESRC = 0x00000010;
1468 const UINT WINEDDCAPS_ALIGNSTRIDE = 0x00000020;
1469 const UINT WINEDDCAPS_BLT = 0x00000040;
1470 const UINT WINEDDCAPS_BLTQUEUE = 0x00000080;
1471 const UINT WINEDDCAPS_BLTFOURCC = 0x00000100;
1472 const UINT WINEDDCAPS_BLTSTRETCH = 0x00000200;
1473 const UINT WINEDDCAPS_GDI = 0x00000400;
1474 const UINT WINEDDCAPS_OVERLAY = 0x00000800;
1475 const UINT WINEDDCAPS_OVERLAYCANTCLIP = 0x00001000;
1476 const UINT WINEDDCAPS_OVERLAYFOURCC = 0x00002000;
1477 const UINT WINEDDCAPS_OVERLAYSTRETCH = 0x00004000;
1478 const UINT WINEDDCAPS_PALETTE = 0x00008000;
1479 const UINT WINEDDCAPS_PALETTEVSYNC = 0x00010000;
1480 const UINT WINEDDCAPS_READSCANLINE = 0x00020000;
1481 const UINT WINEDDCAPS_STEREOVIEW = 0x00040000;
1482 const UINT WINEDDCAPS_VBI = 0x00080000;
1483 const UINT WINEDDCAPS_ZBLTS = 0x00100000;
1484 const UINT WINEDDCAPS_ZOVERLAYS = 0x00200000;
1485 const UINT WINEDDCAPS_COLORKEY = 0x00400000;
1486 const UINT WINEDDCAPS_ALPHA = 0x00800000;
1487 const UINT WINEDDCAPS_COLORKEYHWASSIST = 0x01000000;
1488 const UINT WINEDDCAPS_NOHARDWARE = 0x02000000;
1489 const UINT WINEDDCAPS_BLTCOLORFILL = 0x04000000;
1490 const UINT WINEDDCAPS_BANKSWITCHED = 0x08000000;
1491 const UINT WINEDDCAPS_BLTDEPTHFILL = 0x10000000;
1492 const UINT WINEDDCAPS_CANCLIP = 0x20000000;
1493 const UINT WINEDDCAPS_CANCLIPSTRETCHED = 0x40000000;
1494 const UINT WINEDDCAPS_CANBLTSYSMEM = 0x80000000;
1495
1496 const UINT WINEDDCAPS2_CERTIFIED = 0x00000001;
1497 const UINT WINEDDCAPS2_NO2DDURING3DSCENE = 0x00000002;
1498 const UINT WINEDDCAPS2_VIDEOPORT = 0x00000004;
1499 const UINT WINEDDCAPS2_AUTOFLIPOVERLAY = 0x00000008;
1500 const UINT WINEDDCAPS2_CANBOBINTERLEAVED = 0x00000010;
1501 const UINT WINEDDCAPS2_CANBOBNONINTERLEAVED = 0x00000020;
1502 const UINT WINEDDCAPS2_COLORCONTROLOVERLAY = 0x00000040;
1503 const UINT WINEDDCAPS2_COLORCONTROLPRIMARY = 0x00000080;
1504 const UINT WINEDDCAPS2_CANDROPZ16BIT = 0x00000100;
1505 const UINT WINEDDCAPS2_NONLOCALVIDMEM = 0x00000200;
1506 const UINT WINEDDCAPS2_NONLOCALVIDMEMCAPS = 0x00000400;
1507 const UINT WINEDDCAPS2_NOPAGELOCKREQUIRED = 0x00000800;
1508 const UINT WINEDDCAPS2_WIDESURFACES = 0x00001000;
1509 const UINT WINEDDCAPS2_CANFLIPODDEVEN = 0x00002000;
1510 const UINT WINEDDCAPS2_CANBOBHARDWARE = 0x00004000;
1511 const UINT WINEDDCAPS2_COPYFOURCC = 0x00008000;
1512 const UINT WINEDDCAPS2_PRIMARYGAMMA = 0x00020000;
1513 const UINT WINEDDCAPS2_CANRENDERWINDOWED = 0x00080000;
1514 const UINT WINEDDCAPS2_CANCALIBRATEGAMMA = 0x00100000;
1515 const UINT WINEDDCAPS2_FLIPINTERVAL = 0x00200000;
1516 const UINT WINEDDCAPS2_FLIPNOVSYNC = 0x00400000;
1517 const UINT WINEDDCAPS2_CANMANAGETEXTURE = 0x00800000;
1518 const UINT WINEDDCAPS2_TEXMANINNONLOCALVIDMEM = 0x01000000;
1519 const UINT WINEDDCAPS2_STEREO = 0x02000000;
1520 const UINT WINEDDCAPS2_SYSTONONLOCAL_AS_SYSTOLOCAL = 0x04000000;
1521
1522 /* DDCAPS.d */
1523 const UINT WINEDDPCAPS_4BIT = 0x00000001;
1524 const UINT WINEDDPCAPS_8BITENTRIES = 0x00000002;
1525 const UINT WINEDDPCAPS_8BIT = 0x00000004;
1526 const UINT WINEDDPCAPS_INITIALIZE = 0x00000008;
1527 const UINT WINEDDPCAPS_PRIMARYSURFACE = 0x00000010;
1528 const UINT WINEDDPCAPS_PRIMARYSURFACELEFT = 0x00000020;
1529 const UINT WINEDDPCAPS_ALLOW256 = 0x00000040;
1530 const UINT WINEDDPCAPS_VSYNC = 0x00000080;
1531 const UINT WINEDDPCAPS_1BIT = 0x00000100;
1532 const UINT WINEDDPCAPS_2BIT = 0x00000200;
1533 const UINT WINEDDPCAPS_ALPHA = 0x00000400;
1534
1535 typedef struct _WINED3DDISPLAYMODE
1536 {
1537 UINT Width;
1538 UINT Height;
1539 UINT RefreshRate;
1540 enum wined3d_format_id Format;
1541 } WINED3DDISPLAYMODE;
1542
1543 typedef struct _WINED3DCOLORVALUE
1544 {
1545 float r;
1546 float g;
1547 float b;
1548 float a;
1549 } WINED3DCOLORVALUE;
1550
1551 typedef struct _WINED3DVECTOR
1552 {
1553 float x;
1554 float y;
1555 float z;
1556 } WINED3DVECTOR;
1557
1558 typedef struct _WINED3DMATRIX
1559 {
1560 union
1561 {
1562 struct
1563 {
1564 float _11, _12, _13, _14;
1565 float _21, _22, _23, _24;
1566 float _31, _32, _33, _34;
1567 float _41, _42, _43, _44;
1568 } DUMMYSTRUCTNAME;
1569 float m[4][4];
1570 } DUMMYUNIONNAME;
1571 } WINED3DMATRIX;
1572
1573 typedef struct _WINED3DLIGHT
1574 {
1575 WINED3DLIGHTTYPE Type;
1576 WINED3DCOLORVALUE Diffuse;
1577 WINED3DCOLORVALUE Specular;
1578 WINED3DCOLORVALUE Ambient;
1579 WINED3DVECTOR Position;
1580 WINED3DVECTOR Direction;
1581 float Range;
1582 float Falloff;
1583 float Attenuation0;
1584 float Attenuation1;
1585 float Attenuation2;
1586 float Theta;
1587 float Phi;
1588 } WINED3DLIGHT;
1589
1590 typedef struct _WINED3DMATERIAL
1591 {
1592 WINED3DCOLORVALUE Diffuse;
1593 WINED3DCOLORVALUE Ambient;
1594 WINED3DCOLORVALUE Specular;
1595 WINED3DCOLORVALUE Emissive;
1596 float Power;
1597 } WINED3DMATERIAL;
1598
1599 typedef struct _WINED3DVIEWPORT
1600 {
1601 DWORD X;
1602 DWORD Y;
1603 DWORD Width;
1604 DWORD Height;
1605 float MinZ;
1606 float MaxZ;
1607 } WINED3DVIEWPORT;
1608
1609 typedef struct _WINED3DGAMMARAMP
1610 {
1611 WORD red[256];
1612 WORD green[256];
1613 WORD blue[256];
1614 } WINED3DGAMMARAMP;
1615
1616 typedef struct _WINED3DLINEPATTERN
1617 {
1618 WORD wRepeatFactor;
1619 WORD wLinePattern;
1620 } WINED3DLINEPATTERN;
1621
1622 typedef struct _WINEDD3DRECTPATCH_INFO
1623 {
1624 UINT StartVertexOffsetWidth;
1625 UINT StartVertexOffsetHeight;
1626 UINT Width;
1627 UINT Height;
1628 UINT Stride;
1629 WINED3DBASISTYPE Basis;
1630 WINED3DDEGREETYPE Degree;
1631 } WINED3DRECTPATCH_INFO;
1632
1633 typedef struct _WINED3DTRIPATCH_INFO
1634 {
1635 UINT StartVertexOffset;
1636 UINT NumVertices;
1637 WINED3DBASISTYPE Basis;
1638 WINED3DDEGREETYPE Degree;
1639 } WINED3DTRIPATCH_INFO;
1640
1641 typedef struct _WINED3DADAPTER_IDENTIFIER
1642 {
1643 char *driver;
1644 UINT driver_size;
1645 char *description;
1646 UINT description_size;
1647 char *device_name;
1648 UINT device_name_size;
1649 LARGE_INTEGER driver_version;
1650 DWORD vendor_id;
1651 DWORD device_id;
1652 DWORD subsystem_id;
1653 DWORD revision;
1654 GUID device_identifier;
1655 DWORD whql_level;
1656 LUID adapter_luid;
1657 SIZE_T video_memory;
1658 } WINED3DADAPTER_IDENTIFIER;
1659
1660 typedef struct _WINED3DPRESENT_PARAMETERS
1661 {
1662 UINT BackBufferWidth;
1663 UINT BackBufferHeight;
1664 enum wined3d_format_id BackBufferFormat;
1665 UINT BackBufferCount;
1666 WINED3DMULTISAMPLE_TYPE MultiSampleType;
1667 DWORD MultiSampleQuality;
1668 WINED3DSWAPEFFECT SwapEffect;
1669 HWND hDeviceWindow;
1670 BOOL Windowed;
1671 BOOL EnableAutoDepthStencil;
1672 enum wined3d_format_id AutoDepthStencilFormat;
1673 DWORD Flags;
1674 UINT FullScreen_RefreshRateInHz;
1675 UINT PresentationInterval;
1676 BOOL AutoRestoreDisplayMode;
1677 } WINED3DPRESENT_PARAMETERS;
1678
1679 typedef struct _WINED3DSURFACE_DESC
1680 {
1681 enum wined3d_format_id format;
1682 WINED3DRESOURCETYPE resource_type;
1683 DWORD usage;
1684 WINED3DPOOL pool;
1685 UINT size;
1686 WINED3DMULTISAMPLE_TYPE multisample_type;
1687 DWORD multisample_quality;
1688 UINT width;
1689 UINT height;
1690 } WINED3DSURFACE_DESC;
1691
1692 typedef struct _WINED3DVOLUME_DESC
1693 {
1694 enum wined3d_format_id Format;
1695 WINED3DRESOURCETYPE Type;
1696 DWORD Usage;
1697 WINED3DPOOL Pool;
1698 UINT Size;
1699 UINT Width;
1700 UINT Height;
1701 UINT Depth;
1702 } WINED3DVOLUME_DESC;
1703
1704 typedef struct _WINED3DCLIPSTATUS
1705 {
1706 DWORD ClipUnion;
1707 DWORD ClipIntersection;
1708 } WINED3DCLIPSTATUS;
1709
1710 typedef struct _WINED3DVERTEXELEMENT
1711 {
1712 enum wined3d_format_id format;
1713 WORD input_slot;
1714 WORD offset;
1715 UINT output_slot; /* D3D 8 & 10 */
1716 BYTE method;
1717 BYTE usage;
1718 BYTE usage_idx;
1719 } WINED3DVERTEXELEMENT;
1720
1721 typedef struct _WINED3DDEVICE_CREATION_PARAMETERS
1722 {
1723 UINT AdapterOrdinal;
1724 WINED3DDEVTYPE DeviceType;
1725 HWND hFocusWindow;
1726 DWORD BehaviorFlags;
1727 } WINED3DDEVICE_CREATION_PARAMETERS;
1728
1729 typedef struct _WINED3DDEVINFO_BANDWIDTHTIMINGS
1730 {
1731 float MaxBandwidthUtilized;
1732 float FrontEndUploadMemoryUtilizedPercent;
1733 float VertexRateUtilizedPercent;
1734 float TriangleSetupRateUtilizedPercent;
1735 float FillRateUtilizedPercent;
1736 } WINED3DDEVINFO_BANDWIDTHTIMINGS;
1737
1738 typedef struct _WINED3DDEVINFO_CACHEUTILIZATION
1739 {
1740 float TextureCacheHitRate;
1741 float PostTransformVertexCacheHitRate;
1742 } WINED3DDEVINFO_CACHEUTILIZATION;
1743
1744 typedef struct _WINED3DDEVINFO_INTERFACETIMINGS
1745 {
1746 float WaitingForGPUToUseApplicationResourceTimePercent;
1747 float WaitingForGPUToAcceptMoreCommandsTimePercent;
1748 float WaitingForGPUToStayWithinLatencyTimePercent;
1749 float WaitingForGPUExclusiveResourceTimePercent;
1750 float WaitingForGPUOtherTimePercent;
1751 } WINED3DDEVINFO_INTERFACETIMINGS;
1752
1753 typedef struct _WINED3DDEVINFO_PIPELINETIMINGS
1754 {
1755 float VertexProcessingTimePercent;
1756 float PixelProcessingTimePercent;
1757 float OtherGPUProcessingTimePercent;
1758 float GPUIdleTimePercent;
1759 } WINED3DDEVINFO_PIPELINETIMINGS;
1760
1761 typedef struct _WINED3DDEVINFO_STAGETIMINGS
1762 {
1763 float MemoryProcessingPercent;
1764 float ComputationProcessingPercent;
1765 } WINED3DDEVINFO_STAGETIMINGS;
1766
1767 typedef struct _WINED3DRASTER_STATUS
1768 {
1769 BOOL InVBlank;
1770 UINT ScanLine;
1771 } WINED3DRASTER_STATUS;
1772
1773 typedef struct WINED3DRESOURCESTATS
1774 {
1775 BOOL bThrashing;
1776 DWORD ApproxBytesDownloaded;
1777 DWORD NumEvicts;
1778 DWORD NumVidCreates;
1779 DWORD LastPri;
1780 DWORD NumUsed;
1781 DWORD NumUsedInVidMem;
1782 DWORD WorkingSet;
1783 DWORD WorkingSetBytes;
1784 DWORD TotalManaged;
1785 DWORD TotalBytes;
1786 } WINED3DRESOURCESTATS;
1787
1788 typedef struct _WINED3DDEVINFO_RESOURCEMANAGER
1789 {
1790 WINED3DRESOURCESTATS stats[WINED3DRTYPECOUNT];
1791 } WINED3DDEVINFO_RESOURCEMANAGER;
1792
1793 typedef struct _WINED3DDEVINFO_VERTEXSTATS
1794 {
1795 DWORD NumRenderedTriangles;
1796 DWORD NumExtraClippingTriangles;
1797 } WINED3DDEVINFO_VERTEXSTATS;
1798
1799 typedef struct _WINED3DLOCKED_RECT
1800 {
1801 INT Pitch;
1802 void *pBits;
1803 } WINED3DLOCKED_RECT;
1804
1805 typedef struct _WINED3DLOCKED_BOX
1806 {
1807 INT RowPitch;
1808 INT SlicePitch;
1809 void *pBits;
1810 } WINED3DLOCKED_BOX;
1811
1812 typedef struct _WINED3DBOX
1813 {
1814 UINT Left;
1815 UINT Top;
1816 UINT Right;
1817 UINT Bottom;
1818 UINT Front;
1819 UINT Back;
1820 } WINED3DBOX;
1821
1822 /*Vertex cache optimization hints.*/
1823 typedef struct WINED3DDEVINFO_VCACHE
1824 {
1825 DWORD Pattern; /* Must be a 4 char code FOURCC (e.g. CACH) */
1826 DWORD OptMethod; /* 0 to get the longest strips, 1 vertex cache */
1827 DWORD CacheSize; /* Cache size to use (only valid if OptMethod==1) */
1828 DWORD MagicNumber; /* Internal for deciding when to restart strips,
1829 non user modifiable (only valid if OptMethod==1) */
1830 } WINED3DDEVINFO_VCACHE;
1831
1832 typedef struct _WINED3DBUFFER_DESC
1833 {
1834 WINED3DRESOURCETYPE Type;
1835 DWORD Usage;
1836 WINED3DPOOL Pool;
1837 UINT Size;
1838 } WINED3DBUFFER_DESC;
1839
1840 typedef struct WineDirect3DStridedData
1841 {
1842 enum wined3d_format_id format; /* Format of the data */
1843 const BYTE *lpData; /* Pointer to start of data */
1844 DWORD dwStride; /* Stride between occurrences of this data */
1845 } WineDirect3DStridedData;
1846
1847 typedef struct WineDirect3DVertexStridedData
1848 {
1849 WineDirect3DStridedData position;
1850 WineDirect3DStridedData normal;
1851 WineDirect3DStridedData diffuse;
1852 WineDirect3DStridedData specular;
1853 WineDirect3DStridedData texCoords[WINED3DDP_MAXTEXCOORD];
1854 BOOL position_transformed;
1855 } WineDirect3DVertexStridedData;
1856
1857 typedef struct _WINED3DVSHADERCAPS2_0
1858 {
1859 DWORD Caps;
1860 INT DynamicFlowControlDepth;
1861 INT NumTemps;
1862 INT StaticFlowControlDepth;
1863 } WINED3DVSHADERCAPS2_0;
1864
1865 typedef struct _WINED3DPSHADERCAPS2_0
1866 {
1867 DWORD Caps;
1868 INT DynamicFlowControlDepth;
1869 INT NumTemps;
1870 INT StaticFlowControlDepth;
1871 INT NumInstructionSlots;
1872 } WINED3DPSHADERCAPS2_0;
1873
1874 typedef struct _WINEDDCAPS
1875 {
1876 DWORD Caps;
1877 DWORD Caps2;
1878 DWORD CKeyCaps;
1879 DWORD FXCaps;
1880 DWORD FXAlphaCaps;
1881 DWORD PalCaps;
1882 DWORD SVCaps;
1883 DWORD SVBCaps;
1884 DWORD SVBCKeyCaps;
1885 DWORD SVBFXCaps;
1886 DWORD VSBCaps;
1887 DWORD VSBCKeyCaps;
1888 DWORD VSBFXCaps;
1889 DWORD SSBCaps;
1890 DWORD SSBCKeyCaps;
1891 DWORD SSBFXCaps;
1892 DWORD ddsCaps;
1893 DWORD StrideAlign;
1894 } WINEDDCAPS;
1895
1896 typedef struct _WINED3DCAPS
1897 {
1898 WINED3DDEVTYPE DeviceType;
1899 UINT AdapterOrdinal;
1900
1901 DWORD Caps;
1902 DWORD Caps2;
1903 DWORD Caps3;
1904 DWORD PresentationIntervals;
1905
1906 DWORD CursorCaps;
1907 DWORD DevCaps;
1908 DWORD PrimitiveMiscCaps;
1909 DWORD RasterCaps;
1910 DWORD ZCmpCaps;
1911 DWORD SrcBlendCaps;
1912 DWORD DestBlendCaps;
1913 DWORD AlphaCmpCaps;
1914 DWORD ShadeCaps;
1915 DWORD TextureCaps;
1916 DWORD TextureFilterCaps;
1917 DWORD CubeTextureFilterCaps;
1918 DWORD VolumeTextureFilterCaps;
1919 DWORD TextureAddressCaps;
1920 DWORD VolumeTextureAddressCaps;
1921 DWORD LineCaps;
1922
1923 DWORD MaxTextureWidth;
1924 DWORD MaxTextureHeight;
1925 DWORD MaxVolumeExtent;
1926 DWORD MaxTextureRepeat;
1927 DWORD MaxTextureAspectRatio;
1928 DWORD MaxAnisotropy;
1929 float MaxVertexW;
1930
1931 float GuardBandLeft;
1932 float GuardBandTop;
1933 float GuardBandRight;
1934 float GuardBandBottom;
1935
1936 float ExtentsAdjust;
1937 DWORD StencilCaps;
1938
1939 DWORD FVFCaps;
1940 DWORD TextureOpCaps;
1941 DWORD MaxTextureBlendStages;
1942 DWORD MaxSimultaneousTextures;
1943
1944 DWORD VertexProcessingCaps;
1945 DWORD MaxActiveLights;
1946 DWORD MaxUserClipPlanes;
1947 DWORD MaxVertexBlendMatrices;
1948 DWORD MaxVertexBlendMatrixIndex;
1949
1950 float MaxPointSize;
1951
1952 DWORD MaxPrimitiveCount;
1953 DWORD MaxVertexIndex;
1954 DWORD MaxStreams;
1955 DWORD MaxStreamStride;
1956
1957 DWORD VertexShaderVersion;
1958 DWORD MaxVertexShaderConst;
1959
1960 DWORD PixelShaderVersion;
1961 float PixelShader1xMaxValue;
1962
1963 /* DX 9 */
1964 DWORD DevCaps2;
1965
1966 float MaxNpatchTessellationLevel;
1967 DWORD Reserved5; /* undocumented */
1968
1969 UINT MasterAdapterOrdinal;
1970 UINT AdapterOrdinalInGroup;
1971 UINT NumberOfAdaptersInGroup;
1972 DWORD DeclTypes;
1973 DWORD NumSimultaneousRTs;
1974 DWORD StretchRectFilterCaps;
1975 WINED3DVSHADERCAPS2_0 VS20Caps;
1976 WINED3DPSHADERCAPS2_0 PS20Caps;
1977 DWORD VertexTextureFilterCaps;
1978 DWORD MaxVShaderInstructionsExecuted;
1979 DWORD MaxPShaderInstructionsExecuted;
1980 DWORD MaxVertexShader30InstructionSlots;
1981 DWORD MaxPixelShader30InstructionSlots;
1982 DWORD Reserved2; /* Not in the microsoft headers but documented */
1983 DWORD Reserved3;
1984
1985 WINEDDCAPS DirectDrawCaps;
1986 } WINED3DCAPS;
1987
1988 /* DirectDraw types */
1989
1990 typedef struct _WINEDDCOLORKEY
1991 {
1992 DWORD dwColorSpaceLowValue; /* low boundary of color space that is to
1993 * be treated as Color Key, inclusive */
1994 DWORD dwColorSpaceHighValue; /* high boundary of color space that is
1995 * to be treated as Color Key, inclusive */
1996 } WINEDDCOLORKEY,*LPWINEDDCOLORKEY;
1997
1998 typedef struct _WINEDDBLTFX
1999 {
2000 DWORD dwSize; /* size of structure */
2001 DWORD dwDDFX; /* FX operations */
2002 DWORD dwROP; /* Win32 raster operations */
2003 DWORD dwDDROP; /* Raster operations new for DirectDraw */
2004 DWORD dwRotationAngle; /* Rotation angle for blt */
2005 DWORD dwZBufferOpCode; /* ZBuffer compares */
2006 DWORD dwZBufferLow; /* Low limit of Z buffer */
2007 DWORD dwZBufferHigh; /* High limit of Z buffer */
2008 DWORD dwZBufferBaseDest; /* Destination base value */
2009 DWORD dwZDestConstBitDepth; /* Bit depth used to specify Z constant for destination */
2010 union
2011 {
2012 DWORD dwZDestConst; /* Constant to use as Z buffer for dest */
2013 struct IWineD3DSurface *lpDDSZBufferDest; /* Surface to use as Z buffer for dest */
2014 } DUMMYUNIONNAME1;
2015 DWORD dwZSrcConstBitDepth; /* Bit depth used to specify Z constant for source */
2016 union
2017 {
2018 DWORD dwZSrcConst; /* Constant to use as Z buffer for src */
2019 struct IWineD3DSurface *lpDDSZBufferSrc; /* Surface to use as Z buffer for src */
2020 } DUMMYUNIONNAME2;
2021 DWORD dwAlphaEdgeBlendBitDepth; /* Bit depth used to specify constant for alpha edge blend */
2022 DWORD dwAlphaEdgeBlend; /* Alpha for edge blending */
2023 DWORD dwReserved;
2024 DWORD dwAlphaDestConstBitDepth; /* Bit depth used to specify alpha constant for destination */
2025 union
2026 {
2027 DWORD dwAlphaDestConst; /* Constant to use as Alpha Channel */
2028 struct IWineD3DSurface *lpDDSAlphaDest; /* Surface to use as Alpha Channel */
2029 } DUMMYUNIONNAME3;
2030 DWORD dwAlphaSrcConstBitDepth; /* Bit depth used to specify alpha constant for source */
2031 union
2032 {
2033 DWORD dwAlphaSrcConst; /* Constant to use as Alpha Channel */
2034 struct IWineD3DSurface *lpDDSAlphaSrc; /* Surface to use as Alpha Channel */
2035 } DUMMYUNIONNAME4;
2036 union
2037 {
2038 DWORD dwFillColor; /* color in RGB or Palettized */
2039 DWORD dwFillDepth; /* depth value for z-buffer */
2040 DWORD dwFillPixel; /* pixel val for RGBA or RGBZ */
2041 struct IWineD3DSurface *lpDDSPattern; /* Surface to use as pattern */
2042 } DUMMYUNIONNAME5;
2043 WINEDDCOLORKEY ddckDestColorkey; /* DestColorkey override */
2044 WINEDDCOLORKEY ddckSrcColorkey; /* SrcColorkey override */
2045 } WINEDDBLTFX,*LPWINEDDBLTFX;
2046
2047 typedef struct _WINEDDOVERLAYFX
2048 {
2049 DWORD dwSize; /* size of structure */
2050 DWORD dwAlphaEdgeBlendBitDepth; /* Bit depth used to specify constant for alpha edge blend */
2051 DWORD dwAlphaEdgeBlend; /* Constant to use as alpha for edge blend */
2052 DWORD dwReserved;
2053 DWORD dwAlphaDestConstBitDepth; /* Bit depth used to specify alpha constant for destination */
2054 union
2055 {
2056 DWORD dwAlphaDestConst; /* Constant to use as alpha channel for dest */
2057 struct IWineD3DSurface *lpDDSAlphaDest; /* Surface to use as alpha channel for dest */
2058 } DUMMYUNIONNAME1;
2059 DWORD dwAlphaSrcConstBitDepth; /* Bit depth used to specify alpha constant for source */
2060 union
2061 {
2062 DWORD dwAlphaSrcConst; /* Constant to use as alpha channel for src */
2063 struct IWineD3DSurface *lpDDSAlphaSrc; /* Surface to use as alpha channel for src */
2064 } DUMMYUNIONNAME2;
2065 WINEDDCOLORKEY dckDestColorkey; /* DestColorkey override */
2066 WINEDDCOLORKEY dckSrcColorkey; /* SrcColorkey override */
2067 DWORD dwDDFX; /* Overlay FX */
2068 DWORD dwFlags; /* flags */
2069 } WINEDDOVERLAYFX;
2070
2071 struct wined3d_buffer_desc
2072 {
2073 UINT byte_width;
2074 DWORD usage;
2075 UINT bind_flags;
2076 UINT cpu_access_flags;
2077 UINT misc_flags;
2078 };
2079
2080 struct wined3d_shader_signature_element
2081 {
2082 const char *semantic_name;
2083 UINT semantic_idx;
2084 enum wined3d_sysval_semantic sysval_semantic;
2085 DWORD component_type;
2086 UINT register_idx;
2087 DWORD mask;
2088 };
2089
2090 struct wined3d_shader_signature
2091 {
2092 UINT element_count;
2093 struct wined3d_shader_signature_element *elements;
2094 char *string_data;
2095 };
2096
2097 struct wined3d_parent_ops
2098 {
2099 void (__stdcall *wined3d_object_destroyed)(void *parent);
2100 };
2101
2102 interface IWineD3DResource;
2103 interface IWineD3DSurface;
2104 interface IWineD3DVolume;
2105 interface IWineD3DSwapChain;
2106 interface IWineD3DDevice;
2107
2108 [
2109 object,
2110 local,
2111 uuid(aeb62dfc-bdcb-4f02-9519-1eeea00c15cd)
2112 ]
2113 interface IWineD3DDeviceParent : IUnknown
2114 {
2115 void WineD3DDeviceCreated(
2116 [in] IWineD3DDevice *device
2117 );
2118
2119 HRESULT CreateSurface(
2120 [in] IUnknown *superior,
2121 [in] UINT width,
2122 [in] UINT height,
2123 [in] enum wined3d_format_id format_id,
2124 [in] DWORD usage,
2125 [in] WINED3DPOOL pool,
2126 [in] UINT level,
2127 [in] WINED3DCUBEMAP_FACES face,
2128 [out] IWineD3DSurface **surface
2129 );
2130
2131 HRESULT CreateRenderTarget(
2132 [in] IUnknown *superior,
2133 [in] UINT width,
2134 [in] UINT height,
2135 [in] enum wined3d_format_id format_id,
2136 [in] WINED3DMULTISAMPLE_TYPE multisample_type,
2137 [in] DWORD multisample_quality,
2138 [in] BOOL lockable,
2139 [out] IWineD3DSurface **surface
2140 );
2141
2142 HRESULT CreateDepthStencilSurface(
2143 [in] UINT width,
2144 [in] UINT height,
2145 [in] enum wined3d_format_id format_id,
2146 [in] WINED3DMULTISAMPLE_TYPE multisample_type,
2147 [in] DWORD multisample_quality,
2148 [in] BOOL discard,
2149 [out] IWineD3DSurface **surface
2150 );
2151
2152 HRESULT CreateVolume(
2153 [in] IUnknown *superior,
2154 [in] UINT width,
2155 [in] UINT height,
2156 [in] UINT depth,
2157 [in] enum wined3d_format_id format_id,
2158 [in] WINED3DPOOL pool,
2159 [in] DWORD usage,
2160 [out] IWineD3DVolume **volume
2161 );
2162
2163 HRESULT CreateSwapChain(
2164 [in, out] WINED3DPRESENT_PARAMETERS *present_parameters,
2165 [out] IWineD3DSwapChain **swapchain
2166 );
2167 }
2168 typedef ULONG (__stdcall *D3DCB_DESTROYSWAPCHAINFN)(IWineD3DSwapChain *pSwapChain);
2169 typedef HRESULT (__stdcall *D3DCB_ENUMRESOURCES)(IWineD3DResource *resource, void *pData);
2170
2171 [
2172 object,
2173 local,
2174 uuid(46799311-8e0e-40ce-b2ec-ddb99f18fcb4)
2175 ]
2176 interface IWineD3DBase : IUnknown
2177 {
2178 void *GetParent(
2179 );
2180 }
2181
2182 [
2183 object,
2184 local,
2185 uuid(108f9c44-6f30-11d9-c687-00046142c14f)
2186 ]
2187 interface IWineD3D : IWineD3DBase
2188 {
2189 UINT GetAdapterCount(
2190 );
2191 HRESULT RegisterSoftwareDevice(
2192 [in] void *pInitializeFunction
2193 );
2194 HMONITOR GetAdapterMonitor(
2195 [in] UINT adapter_idx
2196 );
2197 UINT GetAdapterModeCount(
2198 [in] UINT adapter_idx,
2199 [in] enum wined3d_format_id format_id
2200 );
2201 HRESULT EnumAdapterModes(
2202 [in] UINT adapter_idx,
2203 [in] enum wined3d_format_id format_id,
2204 [in] UINT mode_idx,
2205 [out] WINED3DDISPLAYMODE *mode
2206 );
2207 HRESULT GetAdapterDisplayMode(
2208 [in] UINT adapter_idx,
2209 [out] WINED3DDISPLAYMODE *mode
2210 );
2211 HRESULT GetAdapterIdentifier(
2212 [in] UINT adapter_idx,
2213 [in] DWORD flags,
2214 [out] WINED3DADAPTER_IDENTIFIER *identifier
2215 );
2216 HRESULT CheckDeviceMultiSampleType(
2217 [in] UINT adapter_idx,
2218 [in] WINED3DDEVTYPE device_type,
2219 [in] enum wined3d_format_id surface_format_id,
2220 [in] BOOL windowed,
2221 [in] WINED3DMULTISAMPLE_TYPE multisample_type,
2222 [out] DWORD *quality_levels
2223 );
2224 HRESULT CheckDepthStencilMatch(
2225 [in] UINT adapter_idx,
2226 [in] WINED3DDEVTYPE device_type,
2227 [in] enum wined3d_format_id adapter_format_id,
2228 [in] enum wined3d_format_id render_target_format_id,
2229 [in] enum wined3d_format_id depth_stencil_format_id
2230 );
2231 HRESULT CheckDeviceType(
2232 [in] UINT adapter_idx,
2233 [in] WINED3DDEVTYPE device_type,
2234 [in] enum wined3d_format_id display_format_id,
2235 [in] enum wined3d_format_id backbuffer_format_id,
2236 [in] BOOL windowed
2237 );
2238 HRESULT CheckDeviceFormat(
2239 [in] UINT adaper_idx,
2240 [in] WINED3DDEVTYPE device_type,
2241 [in] enum wined3d_format_id adapter_format_id,
2242 [in] DWORD usage,
2243 [in] WINED3DRESOURCETYPE resource_type,
2244 [in] enum wined3d_format_id check_format,
2245 [in] WINED3DSURFTYPE surface_type
2246 );
2247 HRESULT CheckDeviceFormatConversion(
2248 [in] UINT adapter_idx,
2249 [in] WINED3DDEVTYPE device_type,
2250 [in] enum wined3d_format_id source_format_id,
2251 [in] enum wined3d_format_id target_format_id
2252 );
2253 HRESULT GetDeviceCaps(
2254 [in] UINT adapter_idx,
2255 [in] WINED3DDEVTYPE device_type,
2256 [out] WINED3DCAPS *caps
2257 );
2258 HRESULT CreateDevice(
2259 [in] UINT adapter_idx,
2260 [in] WINED3DDEVTYPE device_type,
2261 [in] HWND focus_window,
2262 [in] DWORD behaviour_flags,
2263 [in] IWineD3DDeviceParent *device_parent,
2264 [out] IWineD3DDevice **device
2265 );
2266 }
2267
2268 [
2269 object,
2270 local,
2271 uuid(1f3bfb34-6f30-11d9-c687-00046142c14f)
2272 ]
2273 interface IWineD3DResource : IWineD3DBase
2274 {
2275 HRESULT SetPrivateData(
2276 [in] REFGUID guid,
2277 [in] const void *data,
2278 [in] DWORD data_size,
2279 [in] DWORD flags
2280 );
2281 HRESULT GetPrivateData(
2282 [in] REFGUID guid,
2283 [out] void *data,
2284 [in, out] DWORD *data_size
2285 );
2286 HRESULT FreePrivateData(
2287 [in] REFGUID guid
2288 );
2289 DWORD SetPriority(
2290 [in] DWORD new_priority
2291 );
2292 DWORD GetPriority(
2293 );
2294 void PreLoad(
2295 );
2296 void UnLoad(
2297 );
2298 WINED3DRESOURCETYPE GetType(
2299 );
2300 }
2301
2302 [
2303 object,
2304 local,
2305 uuid(f7d8abf4-fb93-43e4-9c96-4618cf9b3cbc)
2306 ]
2307 interface IWineD3DRendertargetView : IWineD3DBase
2308 {
2309 HRESULT GetResource(
2310 [out] IWineD3DResource **resource
2311 );
2312 }
2313
2314 [
2315 object,
2316 local,
2317 uuid(f756720c-32b9-4439-b5a3-1d6c97037d9e)
2318 ]
2319 interface IWineD3DPalette : IWineD3DBase
2320 {
2321 HRESULT GetEntries(
2322 [in] DWORD flags,
2323 [in] DWORD start,
2324 [in] DWORD count,
2325 [out] PALETTEENTRY *entries
2326 );
2327 HRESULT GetCaps(
2328 [out] DWORD *caps
2329 );
2330 HRESULT SetEntries(
2331 [in] DWORD flags,
2332 [in] DWORD start,
2333 [in] DWORD count,
2334 [in] const PALETTEENTRY *entries
2335 );
2336 }
2337
2338 [
2339 object,
2340 local,
2341 uuid(8f2bceb1-d338-488c-ab7f-0ec980bf5d2d)
2342 ]
2343 interface IWineD3DClipper : IUnknown
2344 {
2345 HRESULT GetClipList(
2346 [in] const RECT *rect,
2347 [out] RGNDATA *clip_list,
2348 [in, out] DWORD *clip_list_size
2349 );
2350 HRESULT GetHWnd(
2351 [out] HWND *hwnd
2352 );
2353 HRESULT IsClipListChanged(
2354 [out] BOOL *changed
2355 );
2356 HRESULT SetClipList(
2357 [in] const RGNDATA *clip_list,
2358 [in] DWORD flags
2359 );
2360 HRESULT SetHWnd(
2361 [in] DWORD flags,
2362 [in] HWND hwnd
2363 );
2364 }
2365
2366 [
2367 object,
2368 local,
2369 uuid(37cd5526-6f30-11d9-c687-00046142c14f)
2370 ]
2371 interface IWineD3DSurface : IWineD3DResource
2372 {
2373 void GetDesc(
2374 [out] WINED3DSURFACE_DESC *desc
2375 );
2376 HRESULT LockRect(
2377 [out] WINED3DLOCKED_RECT *locked_rect,
2378 [in] const RECT *rect,
2379 [in] DWORD flags
2380 );
2381 HRESULT UnlockRect(
2382 );
2383 HRESULT GetDC(
2384 [out] HDC *dc
2385 );
2386 HRESULT ReleaseDC(
2387 [in] HDC dc
2388 );
2389 HRESULT Flip(
2390 [in] IWineD3DSurface *override,
2391 [in] DWORD flags
2392 );
2393 HRESULT Blt(
2394 [in] const RECT *dst_rect,
2395 [in] IWineD3DSurface *src_surface,
2396 [in] const RECT *src_rect,
2397 [in] DWORD flags,
2398 [in] const WINEDDBLTFX *blt_fx,
2399 [in] WINED3DTEXTUREFILTERTYPE filter
2400 );
2401 HRESULT GetBltStatus(
2402 [in] DWORD flags
2403 );
2404 HRESULT GetFlipStatus(
2405 [in] DWORD flags
2406 );
2407 HRESULT IsLost(
2408 );
2409 HRESULT Restore(
2410 );
2411 HRESULT BltFast(
2412 [in] DWORD dst_x,
2413 [in] DWORD dst_y,
2414 [in] IWineD3DSurface *src_surface,
2415 [in] const RECT *src_rect,
2416 [in] DWORD trans
2417 );
2418 HRESULT GetPalette(
2419 [out] IWineD3DPalette **palette
2420 );
2421 HRESULT SetPalette(
2422 [in] IWineD3DPalette *palette
2423 );
2424 HRESULT RealizePalette(
2425 );
2426 HRESULT SetColorKey(
2427 [in] DWORD flags,
2428 [in] const WINEDDCOLORKEY *color_key
2429 );
2430 DWORD GetPitch(
2431 );
2432 HRESULT SetMem(
2433 [in] void *mem
2434 );
2435 HRESULT SetOverlayPosition(
2436 [in] LONG x,
2437 [in] LONG y
2438 );
2439 HRESULT GetOverlayPosition(
2440 [out] LONG *x,
2441 [out] LONG *y
2442 );
2443 HRESULT UpdateOverlayZOrder(
2444 [in] DWORD flags,
2445 [in] IWineD3DSurface *ref
2446 );
2447 HRESULT UpdateOverlay(
2448 [in] const RECT *src_rect,
2449 [in] IWineD3DSurface *dst_surface,
2450 [in] const RECT *dst_rect,
2451 [in] DWORD flags,
2452 [in] const WINEDDOVERLAYFX *fx
2453 );
2454 HRESULT SetClipper(
2455 [in] IWineD3DClipper *clipper
2456 );
2457 HRESULT GetClipper(
2458 [out] IWineD3DClipper **clipper
2459 );
2460 HRESULT LoadTexture(
2461 [in] BOOL srgb_mode
2462 );
2463 void BindTexture(
2464 [in] BOOL srgb
2465 );
2466 const void *GetData(
2467 );
2468 HRESULT SetFormat(
2469 [in] enum wined3d_format_id format_id
2470 );
2471 HRESULT PrivateSetup(
2472 );
2473 WINED3DSURFTYPE GetImplType(
2474 );
2475 HRESULT DrawOverlay(
2476 );
2477 }
2478
2479 [
2480 object,
2481 local,
2482 uuid(24769ed8-6f30-11d9-c687-00046142c14f)
2483 ]
2484 interface IWineD3DVolume : IWineD3DResource
2485 {
2486 void GetDesc(
2487 [out] WINED3DVOLUME_DESC *desc
2488 );
2489 HRESULT LockBox(
2490 [out] WINED3DLOCKED_BOX *locked_box,
2491 [in] const WINED3DBOX *box,
2492 [in] DWORD flags
2493 );
2494 HRESULT UnlockBox(
2495 );
2496 HRESULT LoadTexture(
2497 [in] int gl_level,
2498 [in] BOOL srgb_mode
2499 );
2500 }
2501
2502 [
2503 object,
2504 local,
2505 uuid(3c2aebf6-6f30-11d9-c687-00046142c14f)
2506 ]
2507 interface IWineD3DBaseTexture : IWineD3DResource
2508 {
2509 DWORD SetLOD(
2510 [in] DWORD new_lod
2511 );
2512 DWORD GetLOD(
2513 );
2514 DWORD GetLevelCount(
2515 );
2516 HRESULT SetAutoGenFilterType(
2517 WINED3DTEXTUREFILTERTYPE filter_type
2518 );
2519 WINED3DTEXTUREFILTERTYPE GetAutoGenFilterType(
2520 );
2521 void GenerateMipSubLevels(
2522 );
2523 BOOL SetDirty(
2524 BOOL dirty
2525 );
2526 BOOL GetDirty(
2527 );
2528 HRESULT BindTexture(
2529 [in] BOOL srgb
2530 );
2531 BOOL IsCondNP2(
2532 );
2533 }
2534
2535 [
2536 object,
2537 local,
2538 uuid(3e72cc1c-6f30-11d9-c687-00046142c14f)
2539 ]
2540 interface IWineD3DTexture : IWineD3DBaseTexture
2541 {
2542 HRESULT GetLevelDesc(
2543 [in] UINT level,
2544 [out] WINED3DSURFACE_DESC *desc
2545 );
2546 HRESULT GetSurfaceLevel(
2547 [in] UINT level,
2548 [out] IWineD3DSurface **surface
2549 );
2550 HRESULT LockRect(
2551 [in] UINT level,
2552 [out] WINED3DLOCKED_RECT *locked_rect,
2553 [in] const RECT *rect,
2554 [in] DWORD flags
2555 );
2556 HRESULT UnlockRect(
2557 [in] UINT level
2558 );
2559 HRESULT AddDirtyRect(
2560 [in] const RECT *dirty_rect
2561 );
2562 }
2563
2564 [
2565 object,
2566 local,
2567 uuid(41752900-6f30-11d9-c687-00046142c14f)
2568 ]
2569 interface IWineD3DCubeTexture : IWineD3DBaseTexture
2570 {
2571 HRESULT GetLevelDesc(
2572 [in] UINT level,
2573 [out] WINED3DSURFACE_DESC *desc
2574 );
2575 HRESULT GetCubeMapSurface(
2576 [in] WINED3DCUBEMAP_FACES face,
2577 [in] UINT level,
2578 [out] IWineD3DSurface **surface
2579 );
2580 HRESULT LockRect(
2581 [in] WINED3DCUBEMAP_FACES face,
2582 [in] UINT level,
2583 [out] WINED3DLOCKED_RECT *locked_rect,
2584 [in] const RECT *rect,
2585 [in] DWORD flags
2586 );
2587 HRESULT UnlockRect(
2588 [in] WINED3DCUBEMAP_FACES face,
2589 [in] UINT level
2590 );
2591 HRESULT AddDirtyRect(
2592 [in] WINED3DCUBEMAP_FACES face,
2593 [in] const RECT *dirty_rect
2594 );
2595 }
2596
2597 [
2598 object,
2599 local,
2600 uuid(7b39470c-6f30-11d9-c687-00046142c14f)
2601 ]
2602 interface IWineD3DVolumeTexture : IWineD3DBaseTexture
2603 {
2604 HRESULT GetLevelDesc(
2605 [in] UINT level,
2606 [out] WINED3DVOLUME_DESC *desc
2607 );
2608 HRESULT GetVolumeLevel(
2609 [in] UINT level,
2610 [out] IWineD3DVolume **volume
2611 );
2612 HRESULT LockBox(
2613 [in] UINT level,
2614 [out] WINED3DLOCKED_BOX *locked_box,
2615 [in] const WINED3DBOX *box,
2616 [in] DWORD flags
2617 );
2618 HRESULT UnlockBox(
2619 [in] UINT level
2620 );
2621 HRESULT AddDirtyBox(
2622 [in] const WINED3DBOX *dirty_box
2623 );
2624 }
2625
2626 [
2627 object,
2628 local,
2629 uuid(7cd55be6-6f30-11d9-c687-00046142c14f)
2630 ]
2631 interface IWineD3DVertexDeclaration : IWineD3DBase
2632 {
2633 }
2634
2635 [
2636 object,
2637 local,
2638 uuid(83b073ce-6f30-11d9-c687-00046142c14f)
2639 ]
2640 interface IWineD3DStateBlock : IUnknown
2641 {
2642 HRESULT Capture(
2643 );
2644 HRESULT Apply(
2645 );
2646 }
2647
2648 [
2649 object,
2650 local,
2651 uuid(905ddbac-6f30-11d9-c687-00046142c14f)
2652 ]
2653 interface IWineD3DQuery : IUnknown
2654 {
2655 HRESULT GetData(
2656 [out] void *data,
2657 [in] DWORD data_size,
2658 [in] DWORD flags
2659 );
2660 DWORD GetDataSize(
2661 );
2662 WINED3DQUERYTYPE GetType(
2663 );
2664 HRESULT Issue(
2665 DWORD flags
2666 );
2667 }
2668
2669 [
2670 object,
2671 local,
2672 uuid(34d01b10-6f30-11d9-c687-00046142c14f)
2673 ]
2674 interface IWineD3DSwapChain : IWineD3DBase
2675 {
2676 void Destroy(
2677 );
2678 HRESULT GetDevice(
2679 [out] IWineD3DDevice **device
2680 );
2681 HRESULT Present(
2682 [in] const RECT *src_rect,
2683 [in] const RECT *dst_rect,
2684 [in] HWND dst_window_override,
2685 [in] const RGNDATA *dirty_region,
2686 [in] DWORD flags
2687 );
2688 HRESULT SetDestWindowOverride(
2689 [in] HWND window
2690 );
2691 HRESULT GetFrontBufferData(
2692 [in] IWineD3DSurface *dst_surface
2693 );
2694 HRESULT GetBackBuffer(
2695 [in] UINT backbuffer_idx,
2696 [in] WINED3DBACKBUFFER_TYPE backbuffer_type,
2697 [out] IWineD3DSurface **backbuffer
2698 );
2699 HRESULT GetRasterStatus(
2700 [out] WINED3DRASTER_STATUS *raster_status
2701 );
2702 HRESULT GetDisplayMode(
2703 [out] WINED3DDISPLAYMODE *mode
2704 );
2705 HRESULT GetPresentParameters(
2706 [out] WINED3DPRESENT_PARAMETERS *present_parameters
2707 );
2708 HRESULT SetGammaRamp(
2709 [in] DWORD flags,
2710 [in] const WINED3DGAMMARAMP *ramp
2711 );
2712 HRESULT GetGammaRamp(
2713 [out] WINED3DGAMMARAMP *ramp
2714 );
2715 }
2716
2717 [
2718 object,
2719 local,
2720 uuid(b3f028e8-1a40-4ab3-9292-5bf6cfd80209)
2721 ]
2722 interface IWineD3DBuffer : IWineD3DResource
2723 {
2724 HRESULT Map(
2725 [in] UINT offset,
2726 [in] UINT size,
2727 [out] BYTE **data,
2728 [in] DWORD flags
2729 );
2730 HRESULT Unmap(
2731 );
2732 void GetDesc(
2733 [out] WINED3DBUFFER_DESC *desc
2734 );
2735 }
2736
2737 [
2738 object,
2739 local,
2740 uuid(eac93065-a4df-446f-86a1-9ef2bca40a3c)
2741 ]
2742 interface IWineD3DBaseShader : IWineD3DBase
2743 {
2744 HRESULT GetFunction(
2745 [out] void *data,
2746 [in, out] UINT *data_size
2747 );
2748 }
2749
2750 [
2751 object,
2752 local,
2753 uuid(7f7a2b60-6f30-11d9-c687-00046142c14f)
2754 ]
2755 interface IWineD3DVertexShader : IWineD3DBaseShader
2756 {
2757 HRESULT SetLocalConstantsF(
2758 [in] UINT start_idx,
2759 [in] const float *src_data,
2760 [in] UINT vector4f_count
2761 );
2762 }
2763
2764 [
2765 object,
2766 local,
2767 uuid(8276c113-388b-49d1-ad8b-c9dd8bcbabcd)
2768 ]
2769 interface IWineD3DGeometryShader : IWineD3DBaseShader
2770 {
2771 }
2772
2773 [
2774 object,
2775 local,
2776 uuid(818503da-6f30-11d9-c687-00046142c14f)
2777 ]
2778 interface IWineD3DPixelShader : IWineD3DBaseShader
2779 {
2780 }
2781
2782 [
2783 object,
2784 local,
2785 uuid(6d10a2ce-09d0-4a53-a427-11388f9f8ca5)
2786 ]
2787 interface IWineD3DDevice : IUnknown
2788 {
2789 HRESULT CreateBuffer(
2790 [in] struct wined3d_buffer_desc *desc,
2791 [in] const void *data,
2792 [in] void *parent,
2793 [in] const struct wined3d_parent_ops *parent_ops,
2794 [out] IWineD3DBuffer **buffer
2795 );
2796 HRESULT CreateVertexBuffer(
2797 [in] UINT length,
2798 [in] DWORD usage,
2799 [in] WINED3DPOOL pool,
2800 [in] void *parent,
2801 [in] const struct wined3d_parent_ops *parent_ops,
2802 [out] IWineD3DBuffer **vertex_buffer
2803 );
2804 HRESULT CreateIndexBuffer(
2805 [in] UINT length,
2806 [in] DWORD usage,
2807 [in] WINED3DPOOL pool,
2808 [in] void *parent,
2809 [in] const struct wined3d_parent_ops *parent_ops,
2810 [out] IWineD3DBuffer **index_buffer
2811 );
2812 HRESULT CreateStateBlock(
2813 [in] WINED3DSTATEBLOCKTYPE type,
2814 [out] IWineD3DStateBlock **stateblock
2815 );
2816 HRESULT CreateSurface(
2817 [in] UINT width,
2818 [in] UINT height,
2819 [in] enum wined3d_format_id format_id,
2820 [in] BOOL lockable,
2821 [in] BOOL discard,
2822 [in] UINT level,
2823 [in] DWORD usage,
2824 [in] WINED3DPOOL pool,
2825 [in] WINED3DMULTISAMPLE_TYPE multisample_type,
2826 [in] DWORD multisample_quality,
2827 [in] WINED3DSURFTYPE surface_type,
2828 [in] void *parent,
2829 [in] const struct wined3d_parent_ops *parent_ops,
2830 [out] IWineD3DSurface **surface
2831 );
2832 HRESULT CreateRendertargetView(
2833 [in] IWineD3DResource *resource,
2834 [in] void *parent,
2835 [out] IWineD3DRendertargetView **rendertarget_view
2836 );
2837 HRESULT CreateTexture(
2838 [in] UINT width,
2839 [in] UINT height,
2840 [in] UINT levels,
2841 [in] DWORD usage,
2842 [in] enum wined3d_format_id format_id,
2843 [in] WINED3DPOOL pool,
2844 [in] void *parent,
2845 [in] const struct wined3d_parent_ops *parent_ops,
2846 [out] IWineD3DTexture **texture
2847 );
2848 HRESULT CreateVolumeTexture(
2849 [in] UINT width,
2850 [in] UINT height,
2851 [in] UINT depth,
2852 [in] UINT levels,
2853 [in] DWORD usage,
2854 [in] enum wined3d_format_id format_id,
2855 [in] WINED3DPOOL pool,
2856 [in] void *parent,
2857 [in] const struct wined3d_parent_ops *parent_ops,
2858 [out] IWineD3DVolumeTexture **texture
2859 );
2860 HRESULT CreateVolume(
2861 [in] UINT width,
2862 [in] UINT height,
2863 [in] UINT depth,
2864 [in] DWORD usage,
2865 [in] enum wined3d_format_id format_id,
2866 [in] WINED3DPOOL pool,
2867 [in] void *parent,
2868 [in] const struct wined3d_parent_ops *parent_ops,
2869 [out] IWineD3DVolume **volume
2870 );
2871 HRESULT CreateCubeTexture(
2872 [in] UINT edge_length,
2873 [in] UINT levels,
2874 [in] DWORD usage,
2875 [in] enum wined3d_format_id format_id,
2876 [in] WINED3DPOOL pool,
2877 [in] void *parent,
2878 [in] const struct wined3d_parent_ops *parent_ops,
2879 [out] IWineD3DCubeTexture **texture
2880 );
2881 HRESULT CreateQuery(
2882 [in] WINED3DQUERYTYPE type,
2883 [out] IWineD3DQuery **query
2884 );
2885 HRESULT CreateSwapChain(
2886 [in] WINED3DPRESENT_PARAMETERS *present_parameters,
2887 [in] WINED3DSURFTYPE surface_type,
2888 [in] void *parent,
2889 [out] IWineD3DSwapChain **swapchain
2890 );
2891 HRESULT CreateVertexDeclaration(
2892 [in] const WINED3DVERTEXELEMENT *elements,
2893 [in] UINT element_count,
2894 [in] void *parent,
2895 [in] const struct wined3d_parent_ops *parent_ops,
2896 [out] IWineD3DVertexDeclaration **declaration
2897 );
2898 HRESULT CreateVertexDeclarationFromFVF(
2899 [in] DWORD fvf,
2900 [in] void *parent,
2901 [in] const struct wined3d_parent_ops *parent_ops,
2902 [out] IWineD3DVertexDeclaration **declaration
2903 );
2904 HRESULT CreateVertexShader(
2905 [in] const DWORD *function,
2906 [in] const struct wined3d_shader_signature *output_signature,
2907 [in] void *parent,
2908 [in] const struct wined3d_parent_ops *parent_ops,
2909 [out] IWineD3DVertexShader **shader
2910 );
2911 HRESULT CreateGeometryShader(
2912 [in] const DWORD *byte_code,
2913 [in] const struct wined3d_shader_signature *output_signature,
2914 [in] void *parent,
2915 [in] const struct wined3d_parent_ops *parent_ops,
2916 [out] IWineD3DGeometryShader **shader
2917 );
2918 HRESULT CreatePixelShader(
2919 [in] const DWORD *function,
2920 [in] const struct wined3d_shader_signature *output_signature,
2921 [in] void *parent,
2922 [in] const struct wined3d_parent_ops *parent_ops,
2923 [out] IWineD3DPixelShader **shader
2924 );
2925 HRESULT CreatePalette(
2926 [in] DWORD flags,
2927 [in] const PALETTEENTRY *palette_entry,
2928 [in] void *parent,
2929 [out] IWineD3DPalette **palette
2930 );
2931 HRESULT Init3D(
2932 [in] WINED3DPRESENT_PARAMETERS *present_parameters
2933 );
2934 HRESULT InitGDI(
2935 [in] WINED3DPRESENT_PARAMETERS *present_parameters
2936 );
2937 HRESULT Uninit3D(
2938 [in] D3DCB_DESTROYSWAPCHAINFN destroy_swapchain_callback
2939 );
2940 HRESULT UninitGDI(
2941 [in] D3DCB_DESTROYSWAPCHAINFN destroy_swapchain_callback
2942 );
2943 void SetMultithreaded(
2944 );
2945 HRESULT EvictManagedResources(
2946 );
2947 UINT GetAvailableTextureMem(
2948 );
2949 HRESULT GetBackBuffer(
2950 [in] UINT swapchain_idx,
2951 [in] UINT backbuffer_idx,
2952 [in] WINED3DBACKBUFFER_TYPE backbuffer_type,
2953 [out] IWineD3DSurface **backbuffer
2954 );
2955 HRESULT GetCreationParameters(
2956 [out] WINED3DDEVICE_CREATION_PARAMETERS *creation_parameters
2957 );
2958 HRESULT GetDeviceCaps(
2959 [out] WINED3DCAPS *caps
2960 );
2961 HRESULT GetDirect3D(
2962 [out] IWineD3D** d3d
2963 );
2964 HRESULT GetDisplayMode(
2965 [in] UINT swapchain_idx,
2966 [out] WINED3DDISPLAYMODE *mode
2967 );
2968 HRESULT SetDisplayMode(
2969 [in] UINT swapchain_idx,
2970 [in] const WINED3DDISPLAYMODE *mode
2971 );
2972 UINT GetNumberOfSwapChains(
2973 );
2974 HRESULT GetRasterStatus(
2975 [in] UINT swapchain_idx,
2976 [out] WINED3DRASTER_STATUS *raster_status
2977 );
2978 HRESULT GetSwapChain(
2979 [in] UINT swapchain_idx,
2980 [out] IWineD3DSwapChain **swapchain
2981 );
2982 HRESULT Reset(
2983 [in] WINED3DPRESENT_PARAMETERS *present_parameters
2984 );
2985 HRESULT SetDialogBoxMode(
2986 [in] BOOL enable_dialogs
2987 );
2988 HRESULT SetCursorProperties(
2989 [in] UINT x_hotspot,
2990 [in] UINT y_hotspot,
2991 [in] IWineD3DSurface *cursor_surface
2992 );
2993 void SetCursorPosition(
2994 [in] int x_screen_space,
2995 [in] int y_screen_space,
2996 [in] DWORD flags
2997 );
2998 BOOL ShowCursor(
2999 [in] BOOL show
3000 );
3001 HRESULT SetClipPlane(
3002 [in] DWORD plane_idx,
3003 [in] const float *plane
3004 );
3005 HRESULT GetClipPlane(
3006 [in] DWORD plane_idx,
3007 [out] float *plane
3008 );
3009 HRESULT SetClipStatus(
3010 [in] const WINED3DCLIPSTATUS *clip_status
3011 );
3012 HRESULT GetClipStatus(
3013 [out] WINED3DCLIPSTATUS *clip_status
3014 );
3015 HRESULT SetCurrentTexturePalette(
3016 [in] UINT palette_number
3017 );
3018 HRESULT GetCurrentTexturePalette(
3019 [out] UINT *palette_number
3020 );
3021 HRESULT SetDepthStencilSurface(
3022 [in] IWineD3DSurface *depth_stencil
3023 );
3024 HRESULT GetDepthStencilSurface(
3025 [out] IWineD3DSurface **depth_stencil
3026 );
3027 void SetGammaRamp(
3028 [in] UINT swapchain_idx,
3029 [in] DWORD flags,
3030 [in] const WINED3DGAMMARAMP *ramp
3031 );
3032 void GetGammaRamp(
3033 [in] UINT swapchain_idx,
3034 [out] WINED3DGAMMARAMP *ramp
3035 );
3036 HRESULT SetIndexBuffer(
3037 [in] IWineD3DBuffer *index_buffer,
3038 [in] enum wined3d_format_id format_id
3039 );
3040 HRESULT GetIndexBuffer(
3041 [out] IWineD3DBuffer **index_buffer
3042 );
3043 HRESULT SetBaseVertexIndex(
3044 [in] INT base_index
3045 );
3046 HRESULT GetBaseVertexIndex(
3047 [out] INT *base_index
3048 );
3049 HRESULT SetLight(
3050 [in] DWORD light_idx,
3051 [in] const WINED3DLIGHT *light
3052 );
3053 HRESULT GetLight(
3054 [in] DWORD light_idx,
3055 [out] WINED3DLIGHT *light
3056 );
3057 HRESULT SetLightEnable(
3058 [in] DWORD light_idx,
3059 [in] BOOL enable
3060 );
3061 HRESULT GetLightEnable(
3062 [in] DWORD light_idx,
3063 [out] BOOL *enable
3064 );
3065 HRESULT SetMaterial(
3066 [in] const WINED3DMATERIAL *material
3067 );
3068 HRESULT GetMaterial(
3069 [out] WINED3DMATERIAL *material
3070 );
3071 HRESULT SetNPatchMode(
3072 [in] float segments
3073 );
3074 float GetNPatchMode(
3075 );
3076 HRESULT SetPaletteEntries(
3077 [in] UINT palette_number,
3078 [in] const PALETTEENTRY *entries
3079 );
3080 HRESULT GetPaletteEntries(
3081 [in] UINT palette_number,
3082 [out] PALETTEENTRY *entries
3083 );
3084 HRESULT SetPixelShader(
3085 [in] IWineD3DPixelShader *shader
3086 );
3087 IWineD3DPixelShader *GetPixelShader(
3088 );
3089 HRESULT SetPixelShaderConstantB(
3090 [in] UINT start_register,
3091 [in] const BOOL *constants,
3092 [in] UINT bool_count
3093 );
3094 HRESULT GetPixelShaderConstantB(
3095 [in] UINT start_register,
3096 [out] BOOL *constants,
3097 [in] UINT bool_count
3098 );
3099 HRESULT SetPixelShaderConstantI(
3100 [in] UINT start_register,
3101 [in] const int *constants,
3102 [in] UINT vector4i_count
3103 );
3104 HRESULT GetPixelShaderConstantI(
3105 [in] UINT start_register,
3106 [out] int *constants,
3107 [in] UINT vector4i_count
3108 );
3109 HRESULT SetPixelShaderConstantF(
3110 [in] UINT start_register,
3111 [in] const float *constants,
3112 [in] UINT vector4f_count
3113 );
3114 HRESULT GetPixelShaderConstantF(
3115 [in] UINT start_register,
3116 [out] float *constants,
3117 [in] UINT vector4f_count
3118 );
3119 HRESULT SetRenderState(
3120 [in] WINED3DRENDERSTATETYPE state,
3121 [in] DWORD value
3122 );
3123 HRESULT GetRenderState(
3124 [in] WINED3DRENDERSTATETYPE state,
3125 [out] DWORD *value
3126 );
3127 HRESULT SetRenderTarget(
3128 [in] DWORD render_target_idx,
3129 [in] IWineD3DSurface *render_target,
3130 [in] BOOL set_viewport
3131 );
3132 HRESULT GetRenderTarget(
3133 [in] DWORD render_target_idx,
3134 [out] IWineD3DSurface **render_target
3135 );
3136 HRESULT SetSamplerState(
3137 [in] DWORD sampler_idx,
3138 [in] WINED3DSAMPLERSTATETYPE state,
3139 [in] DWORD value
3140 );
3141 HRESULT GetSamplerState(
3142 [in] DWORD sampler_idx,
3143 [in] WINED3DSAMPLERSTATETYPE state,
3144 [out] DWORD *value
3145 );
3146 HRESULT SetScissorRect(
3147 [in] const RECT *rect
3148 );
3149 HRESULT GetScissorRect(
3150 [out] RECT *rect
3151 );
3152 HRESULT SetSoftwareVertexProcessing(
3153 [in] BOOL software
3154 );
3155 BOOL GetSoftwareVertexProcessing(
3156 );
3157 HRESULT SetStreamSource(
3158 [in] UINT stream_idx,
3159 [in] IWineD3DBuffer *buffer,
3160 [in] UINT offset,
3161 [in] UINT stride
3162 );
3163 HRESULT GetStreamSource(
3164 [in] UINT stream_idx,
3165 [out] IWineD3DBuffer **buffer,
3166 [out] UINT *offset,
3167 [out] UINT *stride
3168 );
3169 HRESULT SetStreamSourceFreq(
3170 [in] UINT stream_idx,
3171 [in] UINT divider
3172 );
3173 HRESULT GetStreamSourceFreq(
3174 [in] UINT stream_idx,
3175 [out] UINT *divider
3176 );
3177 HRESULT SetTexture(
3178 [in] DWORD stage,
3179 [in] IWineD3DBaseTexture *texture
3180 );
3181 HRESULT GetTexture(
3182 [in] DWORD stage,
3183 [out] IWineD3DBaseTexture **texture
3184 );
3185 HRESULT SetTextureStageState(
3186 [in] DWORD stage,
3187 [in] WINED3DTEXTURESTAGESTATETYPE state,
3188 [in] DWORD value
3189 );
3190 HRESULT GetTextureStageState(
3191 [in] DWORD stage,
3192 [in] WINED3DTEXTURESTAGESTATETYPE state,
3193 [out] DWORD *value
3194 );
3195 HRESULT SetTransform(
3196 [in] WINED3DTRANSFORMSTATETYPE state,
3197 [in] const WINED3DMATRIX *matrix
3198 );
3199 HRESULT GetTransform(
3200 [in] WINED3DTRANSFORMSTATETYPE state,
3201 [out] WINED3DMATRIX *matrix
3202 );
3203 HRESULT SetVertexDeclaration(
3204 [in] IWineD3DVertexDeclaration *declaration
3205 );
3206 HRESULT GetVertexDeclaration(
3207 [out] IWineD3DVertexDeclaration **declaration
3208 );
3209 HRESULT SetVertexShader(
3210 [in] IWineD3DVertexShader *shader
3211 );
3212 IWineD3DVertexShader *GetVertexShader(
3213 );
3214 HRESULT SetVertexShaderConstantB(
3215 [in] UINT start_register,
3216 [in] const BOOL *constants,
3217 [in] UINT bool_count
3218 );
3219 HRESULT GetVertexShaderConstantB(
3220 [in] UINT start_register,
3221 [out] BOOL *constants,
3222 [in] UINT bool_count
3223 );
3224 HRESULT SetVertexShaderConstantI(
3225 [in] UINT start_register,
3226 [in] const int *constants,
3227 [in] UINT vector4i_count
3228 );
3229 HRESULT GetVertexShaderConstantI(
3230 [in] UINT start_register,
3231 [out] int *constants,
3232 [in] UINT vector4i_count
3233 );
3234 HRESULT SetVertexShaderConstantF(
3235 [in] UINT start_register,
3236 [in] const float *constants,
3237 [in] UINT vector4f_count
3238 );
3239 HRESULT GetVertexShaderConstantF(
3240 [in] UINT start_register,
3241 [out] float *constants,
3242 [in] UINT vector4f_count
3243 );
3244 HRESULT SetViewport(
3245 [in] const WINED3DVIEWPORT *viewport
3246 );
3247 HRESULT GetViewport(
3248 [out] WINED3DVIEWPORT *viewport
3249 );
3250 HRESULT MultiplyTransform(
3251 [in] WINED3DTRANSFORMSTATETYPE state,
3252 [in] const WINED3DMATRIX *matrix
3253 );
3254 HRESULT ValidateDevice(
3255 [out] DWORD *num_passes
3256 );
3257 HRESULT ProcessVertices(
3258 [in] UINT src_start_idx,
3259 [in] UINT dst_idx,
3260 [in] UINT vertex_count,
3261 [in] IWineD3DBuffer *dest_buffer,
3262 [in] IWineD3DVertexDeclaration *declaration,
3263 [in] DWORD flags,
3264 [in] DWORD DestFVF
3265 );
3266 HRESULT BeginStateBlock(
3267 );
3268 HRESULT EndStateBlock(
3269 [out] IWineD3DStateBlock **stateblock
3270 );
3271 HRESULT BeginScene(
3272 );
3273 HRESULT EndScene(
3274 );
3275 HRESULT Present(
3276 [in] const RECT *src_rect,
3277 [in] const RECT *dst_rect,
3278 [in] HWND dst_window_override,
3279 [in] const RGNDATA *dirty_region
3280 );
3281 HRESULT Clear(
3282 [in] DWORD rect_count,
3283 [in] const RECT *rects,
3284 [in] DWORD flags,
3285 [in] WINED3DCOLOR color,
3286 [in] float z,
3287 [in] DWORD stencil
3288 );
3289 void ClearRendertargetView(
3290 [in] IWineD3DRendertargetView *rendertarget_view,
3291 [in] const WINED3DCOLORVALUE *color
3292 );
3293 void SetPrimitiveType(
3294 [in] WINED3DPRIMITIVETYPE primitive_topology
3295 );
3296 void GetPrimitiveType(
3297 [out] WINED3DPRIMITIVETYPE *primitive_topology
3298 );
3299 HRESULT DrawPrimitive(
3300 [in] UINT start_vertex,
3301 [in] UINT vertex_count
3302 );
3303 HRESULT DrawIndexedPrimitive(
3304 [in] UINT start_idx,
3305 [in] UINT index_count
3306 );
3307 HRESULT DrawPrimitiveUP(
3308 [in] UINT vertex_count,
3309 [in] const void *stream_data,
3310 [in] UINT stream_stride
3311 );
3312 HRESULT DrawIndexedPrimitiveUP(
3313 [in] UINT index_count,
3314 [in] const void *index_data,
3315 [in] enum wined3d_format_id index_data_format_id,
3316 [in] const void *stream_data,
3317 [in] UINT stream_stride
3318 );
3319 HRESULT DrawPrimitiveStrided(
3320 [in] UINT vertex_count,
3321 [in] const WineDirect3DVertexStridedData *strided_data
3322 );
3323 HRESULT DrawIndexedPrimitiveStrided(
3324 [in] UINT index_count,
3325 [in] const WineDirect3DVertexStridedData *strided_data,
3326 [in] UINT vertex_count,
3327 [in] const void *index_data,
3328 [in] enum wined3d_format_id index_data_format_id
3329 );
3330 HRESULT DrawRectPatch(
3331 [in] UINT handle,
3332 [in] const float *num_segs,
3333 [in] const WINED3DRECTPATCH_INFO *rect_patch_info
3334 );
3335 HRESULT DrawTriPatch(
3336 [in] UINT handle,
3337 [in] const float *num_segs,
3338 [in] const WINED3DTRIPATCH_INFO *tri_patch_info
3339 );
3340 HRESULT DeletePatch(
3341 [in] UINT handle
3342 );
3343 HRESULT ColorFill(
3344 [in] IWineD3DSurface *surface,
3345 [in] const RECT *rect,
3346 [in] const WINED3DCOLORVALUE *color
3347 );
3348 HRESULT UpdateTexture(
3349 [in] IWineD3DBaseTexture *src_texture,
3350 [in] IWineD3DBaseTexture *dst_texture
3351 );
3352 HRESULT UpdateSurface(
3353 [in] IWineD3DSurface *src_surface,
3354 [in] const RECT *src_rect,
3355 [in] IWineD3DSurface *dst_surface,
3356 [in] const POINT *dst_point
3357 );
3358 HRESULT GetFrontBufferData(
3359 [in] UINT swapchain_idx,
3360 [in] IWineD3DSurface *dst_surface
3361 );
3362 HRESULT EnumResources(
3363 [in] D3DCB_ENUMRESOURCES callback,
3364 [in] void *data
3365 );
3366 HRESULT GetSurfaceFromDC(
3367 [in] HDC dc,
3368 [out] IWineD3DSurface **surface
3369 );
3370 HRESULT AcquireFocusWindow(
3371 [in] HWND window
3372 );
3373 void ReleaseFocusWindow(
3374 );
3375 }
3376
3377 IWineD3D *WineDirect3DCreate(UINT dxVersion, void *parent);
3378 IWineD3DClipper *WineDirect3DCreateClipper(void);
3379 void wined3d_mutex_lock(void);
3380 void wined3d_mutex_unlock(void);