source: Daodan/MSYS2/mingw32/i686-w64-mingw32/include/d3dx9mesh.h@ 1172

Last change on this file since 1172 was 1166, checked in by rossy, 3 years ago

Daodan: Replace MinGW build env with an up-to-date MSYS2 env

File size: 53.7 KB
Line 
1#include <_mingw_unicode.h>
2#undef INTERFACE
3/*
4 * Copyright (C) 2009 David Adam
5 * Copyright (C) 2010 Tony Wasserka
6 *
7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Lesser General Public
9 * License as published by the Free Software Foundation; either
10 * version 2.1 of the License, or (at your option) any later version.
11 *
12 * This library is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * Lesser General Public License for more details.
16 *
17 * You should have received a copy of the GNU Lesser General Public
18 * License along with this library; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
20 */
21
22#include "d3dx9.h"
23
24#ifndef __WINE_D3DX9MESH_H
25#define __WINE_D3DX9MESH_H
26
27DEFINE_GUID(IID_ID3DXBaseMesh, 0x7ed943dd, 0x52e8, 0x40b5, 0xa8, 0xd8, 0x76, 0x68, 0x5c, 0x40, 0x63, 0x30);
28DEFINE_GUID(IID_ID3DXMesh, 0x4020e5c2, 0x1403, 0x4929, 0x88, 0x3f, 0xe2, 0xe8, 0x49, 0xfa, 0xc1, 0x95);
29DEFINE_GUID(IID_ID3DXPMesh, 0x8875769a, 0xd579, 0x4088, 0xaa, 0xeb, 0x53, 0x4d, 0x1a, 0xd8, 0x4e, 0x96);
30DEFINE_GUID(IID_ID3DXSPMesh, 0x667ea4c7, 0xf1cd, 0x4386, 0xb5, 0x23, 0x7c, 0x02, 0x90, 0xb8, 0x3c, 0xc5);
31DEFINE_GUID(IID_ID3DXSkinInfo, 0x11eaa540, 0xf9a6, 0x4d49, 0xae, 0x6a, 0xe1, 0x92, 0x21, 0xf7, 0x0c, 0xc4);
32DEFINE_GUID(IID_ID3DXPatchMesh,0x3ce6cc22, 0xdbf2, 0x44f4, 0x89, 0x4d, 0xf9, 0xc3, 0x4a, 0x33, 0x71, 0x39);
33DEFINE_GUID(IID_ID3DXPRTBuffer, 0xf1827e47, 0x00a8, 0x49cd, 0x90, 0x8c, 0x9d, 0x11, 0x95, 0x5f, 0x87, 0x28);
34DEFINE_GUID(IID_ID3DXPRTCompBuffer, 0xa758d465, 0xfe8d, 0x45ad, 0x9c, 0xf0, 0xd0, 0x1e, 0x56, 0x26, 0x6a, 0x07);
35DEFINE_GUID(IID_ID3DXTextureGutterHelper, 0x838f01ec, 0x9729, 0x4527, 0xaa, 0xdb, 0xdf, 0x70, 0xad, 0xe7, 0xfe, 0xa9);
36DEFINE_GUID(IID_ID3DXPRTEngine, 0x683a4278, 0xcd5f, 0x4d24, 0x90, 0xad, 0xc4, 0xe1, 0xb6, 0x85, 0x5d, 0x53);
37
38#define UNUSED16 (0xffff)
39#define UNUSED32 (0xffffffff)
40
41enum _MAX_FVF_DECL_SIZE
42{
43 MAX_FVF_DECL_SIZE = MAXD3DDECLLENGTH + 1
44};
45
46enum _D3DXMESH
47{
48 D3DXMESH_32BIT = 0x001,
49 D3DXMESH_DONOTCLIP = 0x002,
50 D3DXMESH_POINTS = 0x004,
51 D3DXMESH_RTPATCHES = 0x008,
52 D3DXMESH_NPATCHES = 0x4000,
53 D3DXMESH_VB_SYSTEMMEM = 0x010,
54 D3DXMESH_VB_MANAGED = 0x020,
55 D3DXMESH_VB_WRITEONLY = 0x040,
56 D3DXMESH_VB_DYNAMIC = 0x080,
57 D3DXMESH_VB_SOFTWAREPROCESSING = 0x8000,
58 D3DXMESH_IB_SYSTEMMEM = 0x100,
59 D3DXMESH_IB_MANAGED = 0x200,
60 D3DXMESH_IB_WRITEONLY = 0x400,
61 D3DXMESH_IB_DYNAMIC = 0x800,
62 D3DXMESH_IB_SOFTWAREPROCESSING = 0x10000,
63 D3DXMESH_VB_SHARE = 0x1000,
64 D3DXMESH_USEHWONLY = 0x2000,
65 D3DXMESH_SYSTEMMEM = 0x110,
66 D3DXMESH_MANAGED = 0x220,
67 D3DXMESH_WRITEONLY = 0x440,
68 D3DXMESH_DYNAMIC = 0x880,
69 D3DXMESH_SOFTWAREPROCESSING = 0x18000
70};
71
72enum _D3DXMESHOPT
73{
74 D3DXMESHOPT_DEVICEINDEPENDENT = 0x00400000,
75 D3DXMESHOPT_COMPACT = 0x01000000,
76 D3DXMESHOPT_ATTRSORT = 0x02000000,
77 D3DXMESHOPT_VERTEXCACHE = 0x04000000,
78 D3DXMESHOPT_STRIPREORDER = 0x08000000,
79 D3DXMESHOPT_IGNOREVERTS = 0x10000000,
80 D3DXMESHOPT_DONOTSPLIT = 0x20000000,
81};
82
83typedef enum _D3DXPATCHMESHTYPE
84{
85 D3DXPATCHMESH_RECT = 1,
86 D3DXPATCHMESH_TRI = 2,
87 D3DXPATCHMESH_NPATCH = 3,
88 D3DXPATCHMESH_FORCE_DWORD = 0x7fffffff,
89} D3DXPATCHMESHTYPE;
90
91enum _D3DXPATCHMESH
92{
93 D3DXPATCHMESH_DEFAULT = 0,
94};
95
96enum _D3DXMESHSIMP
97{
98 D3DXMESHSIMP_VERTEX = 0x1,
99 D3DXMESHSIMP_FACE = 0x2,
100};
101
102typedef enum D3DXCLEANTYPE {
103 D3DXCLEAN_BACKFACING = 0x00000001,
104 D3DXCLEAN_BOWTIES = 0x00000002,
105
106 D3DXCLEAN_SKINNING = D3DXCLEAN_BACKFACING,
107 D3DXCLEAN_OPTIMIZATION = D3DXCLEAN_BACKFACING,
108 D3DXCLEAN_SIMPLIFICATION = D3DXCLEAN_BACKFACING | D3DXCLEAN_BOWTIES,
109} D3DXCLEANTYPE;
110
111typedef enum _D3DXTANGENT
112{
113 D3DXTANGENT_WRAP_U = 0x0001,
114 D3DXTANGENT_WRAP_V = 0x0002,
115 D3DXTANGENT_WRAP_UV = 0x0003,
116 D3DXTANGENT_DONT_NORMALIZE_PARTIALS = 0x0004,
117 D3DXTANGENT_DONT_ORTHOGONALIZE = 0x0008,
118 D3DXTANGENT_ORTHOGONALIZE_FROM_V = 0x0010,
119 D3DXTANGENT_ORTHOGONALIZE_FROM_U = 0x0020,
120 D3DXTANGENT_WEIGHT_BY_AREA = 0x0040,
121 D3DXTANGENT_WEIGHT_EQUAL = 0x0080,
122 D3DXTANGENT_WIND_CW = 0x0100,
123 D3DXTANGENT_CALCULATE_NORMALS = 0x0200,
124 D3DXTANGENT_GENERATE_IN_PLACE = 0x0400,
125} D3DXTANGENT;
126
127typedef enum _D3DXIMT
128{
129 D3DXIMT_WRAP_U = 0x01,
130 D3DXIMT_WRAP_V = 0x02,
131 D3DXIMT_WRAP_UV = 0x03,
132} D3DXIMT;
133
134typedef enum _D3DXUVATLAS
135{
136 D3DXUVATLAS_DEFAULT = 0x00,
137 D3DXUVATLAS_GEODESIC_FAST = 0x01,
138 D3DXUVATLAS_GEODESIC_QUALITY = 0x02,
139} D3DXUVATLAS;
140
141typedef enum _D3DXEFFECTDEFAULTTYPE
142{
143 D3DXEDT_STRING = 1,
144 D3DXEDT_FLOATS = 2,
145 D3DXEDT_DWORD = 3,
146 D3DXEDT_FORCEDWORD = 0x7fffffff,
147} D3DXEFFECTDEFAULTTYPE;
148
149enum _D3DXWELDEPSILONSFLAGS
150{
151 D3DXWELDEPSILONS_WELDALL = 0x1,
152 D3DXWELDEPSILONS_WELDPARTIALMATCHES = 0x2,
153 D3DXWELDEPSILONS_DONOTREMOVEVERTICES = 0x4,
154 D3DXWELDEPSILONS_DONOTSPLIT = 0x8,
155};
156
157typedef enum _D3DXSHCOMPRESSQUALITYTYPE
158{
159 D3DXSHCQUAL_FASTLOWQUALITY = 1,
160 D3DXSHCQUAL_SLOWHIGHQUALITY = 2,
161 D3DXSHCQUAL_FORCE_DWORD = 0x7fffffff,
162} D3DXSHCOMPRESSQUALITYTYPE;
163
164typedef enum _D3DXSHGPUSIMOPT
165{
166 D3DXSHGPUSIMOPT_SHADOWRES256 = 1,
167 D3DXSHGPUSIMOPT_SHADOWRES512 = 0,
168 D3DXSHGPUSIMOPT_SHADOWRES1024 = 2,
169 D3DXSHGPUSIMOPT_SHADOWRES2048 = 3,
170 D3DXSHGPUSIMOPT_HIGHQUALITY = 4,
171 D3DXSHGPUSIMOPT_FORCE_DWORD = 0x7fffffff,
172} D3DXSHGPUSIMOPT;
173
174typedef struct ID3DXBaseMesh* LPD3DXBASEMESH;
175typedef struct ID3DXMesh* LPD3DXMESH;
176typedef struct ID3DXPMesh *LPD3DXPMESH;
177typedef struct ID3DXSPMesh *LPD3DXSPMESH;
178typedef struct ID3DXSkinInfo *LPD3DXSKININFO;
179typedef struct ID3DXPatchMesh *LPD3DXPATCHMESH;
180typedef struct ID3DXPRTBuffer *LPD3DXPRTBUFFER;
181typedef struct ID3DXPRTCompBuffer *LPD3DXPRTCOMPBUFFER;
182typedef struct ID3DXPRTEngine *LPD3DXPRTENGINE;
183typedef struct ID3DXTextureGutterHelper *LPD3DXTEXTUREGUTTERHELPER;
184
185typedef struct _D3DXATTRIBUTERANGE {
186 DWORD AttribId;
187 DWORD FaceStart;
188 DWORD FaceCount;
189 DWORD VertexStart;
190 DWORD VertexCount;
191} D3DXATTRIBUTERANGE;
192
193typedef D3DXATTRIBUTERANGE* LPD3DXATTRIBUTERANGE;
194
195typedef struct _D3DXMATERIAL
196{
197 D3DMATERIAL9 MatD3D;
198 char *pTextureFilename;
199} D3DXMATERIAL, *LPD3DXMATERIAL;
200
201typedef struct _D3DXEFFECTDEFAULT
202{
203 char *pParamName;
204 D3DXEFFECTDEFAULTTYPE Type;
205 DWORD NumBytes;
206 void *pValue;
207} D3DXEFFECTDEFAULT, *LPD3DXEFFECTDEFAULT;
208
209typedef struct _D3DXEFFECTINSTANCE
210{
211 char *pEffectFilename;
212 DWORD NumDefaults;
213 LPD3DXEFFECTDEFAULT pDefaults;
214} D3DXEFFECTINSTANCE, *LPD3DXEFFECTINSTANCE;
215
216typedef struct _D3DXATTRIBUTEWEIGHTS
217{
218 FLOAT Position;
219 FLOAT Boundary;
220 FLOAT Normal;
221 FLOAT Diffuse;
222 FLOAT Specular;
223 FLOAT Texcoords[8];
224 FLOAT Tangent;
225 FLOAT Binormal;
226} D3DXATTRIBUTEWEIGHTS, *LPD3DXATTRIBUTEWEIGHTS;
227
228typedef struct _D3DXWELDEPSILONS
229{
230 FLOAT Position;
231 FLOAT BlendWeights;
232 FLOAT Normals;
233 FLOAT PSize;
234 FLOAT Specular;
235 FLOAT Diffuse;
236 FLOAT Texcoords[8];
237 FLOAT Tangent;
238 FLOAT Binormal;
239 FLOAT TessFactor;
240} D3DXWELDEPSILONS, *LPD3DXWELDEPSILONS;
241
242typedef struct _D3DXBONECOMBINATION
243{
244 DWORD AttribId;
245 DWORD FaceStart;
246 DWORD FaceCount;
247 DWORD VertexStart;
248 DWORD VertexCout;
249 DWORD *BoneId;
250} D3DXBONECOMBINATION, *LPD3DXBONECOMBINATION;
251
252typedef struct _D3DXPATCHINFO
253{
254 D3DXPATCHMESHTYPE PatchType;
255 D3DDEGREETYPE Degree;
256 D3DBASISTYPE Basis;
257} D3DXPATCHINFO, *LPD3DXPATCHINFO;
258
259typedef struct _D3DXINTERSECTINFO
260{
261 DWORD FaceIndex;
262 FLOAT U;
263 FLOAT V;
264 FLOAT Dist;
265} D3DXINTERSECTINFO, *LPD3DXINTERSECTINFO;
266
267typedef struct _D3DXSHMATERIAL
268{
269 D3DCOLORVALUE Diffuse;
270 WINBOOL bMirror;
271 WINBOOL bSubSurf;
272 FLOAT RelativeIndexOfRefraction;
273 D3DCOLORVALUE Absorption;
274 D3DCOLORVALUE ReducedScattering;
275} D3DXSHMATERIAL;
276
277typedef struct _D3DXSHPRTSPLITMESHVERTDATA
278{
279 UINT uVertRemap;
280 UINT uSubCluster;
281 UCHAR ucVertStatus;
282} D3DXSHPRTSPLITMESHVERTDATA;
283
284typedef struct _D3DXSHPRTSPLITMESHCLUSTERDATA
285{
286 UINT uVertStart;
287 UINT uVertLength;
288 UINT uFaceStart;
289 UINT uFaceLength;
290 UINT uClusterStart;
291 UINT uClusterLength;
292} D3DXSHPRTSPLITMESHCLUSTERDATA;
293
294typedef struct _XFILECOMPRESSEDANIMATIONSET
295{
296 DWORD CompressedBlockSize;
297 FLOAT TicksPerSec;
298 DWORD PlaybackType;
299 DWORD BufferLength;
300} XFILECOMPRESSEDANIMATIONSET;
301
302typedef HRESULT (WINAPI *LPD3DXUVATLASCB)(float complete, void *ctx);
303typedef HRESULT (WINAPI *LPD3DXIMTSIGNALCALLBACK)(const D3DXVECTOR2 *, UINT, UINT, void *, FLOAT *);
304typedef HRESULT (WINAPI *LPD3DXSHPRTSIMCB)(float complete, void *ctx);
305
306#undef INTERFACE
307#define INTERFACE ID3DXBaseMesh
308
309DECLARE_INTERFACE_(ID3DXBaseMesh, IUnknown)
310{
311 /*** IUnknown methods ***/
312 STDMETHOD(QueryInterface)(THIS_ REFIID riid, void **out) PURE;
313 STDMETHOD_(ULONG, AddRef)(THIS) PURE;
314 STDMETHOD_(ULONG, Release)(THIS) PURE;
315 /*** ID3DXBaseMesh ***/
316 STDMETHOD(DrawSubset)(THIS_ DWORD attrib_id) PURE;
317 STDMETHOD_(DWORD, GetNumFaces)(THIS) PURE;
318 STDMETHOD_(DWORD, GetNumVertices)(THIS) PURE;
319 STDMETHOD_(DWORD, GetFVF)(THIS) PURE;
320 STDMETHOD(GetDeclaration)(THIS_ D3DVERTEXELEMENT9 declaration[MAX_FVF_DECL_SIZE]) PURE;
321 STDMETHOD_(DWORD, GetNumBytesPerVertex)(THIS) PURE;
322 STDMETHOD_(DWORD, GetOptions)(THIS) PURE;
323 STDMETHOD(GetDevice)(THIS_ struct IDirect3DDevice9 **device) PURE;
324 STDMETHOD(CloneMeshFVF)(THIS_ DWORD options, DWORD fvf,
325 struct IDirect3DDevice9 *device, struct ID3DXMesh **clone_mesh) PURE;
326 STDMETHOD(CloneMesh)(THIS_ DWORD options, const D3DVERTEXELEMENT9 *declaration,
327 struct IDirect3DDevice9 *device, struct ID3DXMesh **clone_mesh) PURE;
328 STDMETHOD(GetVertexBuffer)(THIS_ struct IDirect3DVertexBuffer9 **vertex_buffer) PURE;
329 STDMETHOD(GetIndexBuffer)(THIS_ struct IDirect3DIndexBuffer9 **index_buffer) PURE;
330 STDMETHOD(LockVertexBuffer)(THIS_ DWORD flags, void **data) PURE;
331 STDMETHOD(UnlockVertexBuffer)(THIS) PURE;
332 STDMETHOD(LockIndexBuffer)(THIS_ DWORD flags, void **data) PURE;
333 STDMETHOD(UnlockIndexBuffer)(THIS) PURE;
334 STDMETHOD(GetAttributeTable)(THIS_ D3DXATTRIBUTERANGE* attrib_table, DWORD* attrib_table_size) PURE;
335 STDMETHOD(ConvertPointRepsToAdjacency)(THIS_ const DWORD *point_reps, DWORD *adjacency) PURE;
336 STDMETHOD(ConvertAdjacencyToPointReps)(THIS_ const DWORD *adjacency, DWORD *point_reps) PURE;
337 STDMETHOD(GenerateAdjacency)(THIS_ FLOAT epsilon, DWORD* adjacency) PURE;
338 STDMETHOD(UpdateSemantics)(THIS_ D3DVERTEXELEMENT9 declaration[MAX_FVF_DECL_SIZE]) PURE;
339};
340#undef INTERFACE
341
342#define INTERFACE ID3DXMesh
343DECLARE_INTERFACE_(ID3DXMesh, ID3DXBaseMesh)
344{
345 /*** IUnknown methods ***/
346 STDMETHOD(QueryInterface)(THIS_ REFIID riid, void **out) PURE;
347 STDMETHOD_(ULONG, AddRef)(THIS) PURE;
348 STDMETHOD_(ULONG, Release)(THIS) PURE;
349 /*** ID3DXBaseMesh ***/
350 STDMETHOD(DrawSubset)(THIS_ DWORD attrib_id) PURE;
351 STDMETHOD_(DWORD, GetNumFaces)(THIS) PURE;
352 STDMETHOD_(DWORD, GetNumVertices)(THIS) PURE;
353 STDMETHOD_(DWORD, GetFVF)(THIS) PURE;
354 STDMETHOD(GetDeclaration)(THIS_ D3DVERTEXELEMENT9 declaration[MAX_FVF_DECL_SIZE]) PURE;
355 STDMETHOD_(DWORD, GetNumBytesPerVertex)(THIS) PURE;
356 STDMETHOD_(DWORD, GetOptions)(THIS) PURE;
357 STDMETHOD(GetDevice)(THIS_ struct IDirect3DDevice9 **device) PURE;
358 STDMETHOD(CloneMeshFVF)(THIS_ DWORD options, DWORD fvf,
359 struct IDirect3DDevice9 *device, struct ID3DXMesh **clone_mesh) PURE;
360 STDMETHOD(CloneMesh)(THIS_ DWORD options, const D3DVERTEXELEMENT9 *declaration,
361 struct IDirect3DDevice9 *device, struct ID3DXMesh **clone_mesh) PURE;
362 STDMETHOD(GetVertexBuffer)(THIS_ struct IDirect3DVertexBuffer9 **vertex_buffer) PURE;
363 STDMETHOD(GetIndexBuffer)(THIS_ struct IDirect3DIndexBuffer9 **index_buffer) PURE;
364 STDMETHOD(LockVertexBuffer)(THIS_ DWORD flags, void **data) PURE;
365 STDMETHOD(UnlockVertexBuffer)(THIS) PURE;
366 STDMETHOD(LockIndexBuffer)(THIS_ DWORD flags, void **data) PURE;
367 STDMETHOD(UnlockIndexBuffer)(THIS) PURE;
368 STDMETHOD(GetAttributeTable)(THIS_ D3DXATTRIBUTERANGE* attrib_table, DWORD* attrib_table_size) PURE;
369 STDMETHOD(ConvertPointRepsToAdjacency)(THIS_ const DWORD *point_reps, DWORD *adjacency) PURE;
370 STDMETHOD(ConvertAdjacencyToPointReps)(THIS_ const DWORD *adjacency, DWORD *point_reps) PURE;
371 STDMETHOD(GenerateAdjacency)(THIS_ FLOAT epsilon, DWORD* adjacency) PURE;
372 STDMETHOD(UpdateSemantics)(THIS_ D3DVERTEXELEMENT9 declaration[MAX_FVF_DECL_SIZE]) PURE;
373 /*** ID3DXMesh ***/
374 STDMETHOD(LockAttributeBuffer)(THIS_ DWORD flags, DWORD** data) PURE;
375 STDMETHOD(UnlockAttributeBuffer)(THIS) PURE;
376 STDMETHOD(Optimize)(THIS_ DWORD flags, const DWORD *adjacency_in, DWORD *adjacency_out,
377 DWORD *face_remap, ID3DXBuffer **vertex_remap, ID3DXMesh **opt_mesh) PURE;
378 STDMETHOD(OptimizeInplace)(THIS_ DWORD flags, const DWORD *adjacency_in, DWORD *adjacency_out,
379 DWORD *face_remap, ID3DXBuffer **vertex_remap) PURE;
380 STDMETHOD(SetAttributeTable)(THIS_ const D3DXATTRIBUTERANGE *attrib_table,
381 DWORD attrib_table_size) PURE;
382};
383#undef INTERFACE
384
385#define INTERFACE ID3DXPMesh
386DECLARE_INTERFACE_(ID3DXPMesh, ID3DXBaseMesh)
387{
388 /*** IUnknown methods ***/
389 STDMETHOD(QueryInterface)(THIS_ REFIID riid, void **out) PURE;
390 STDMETHOD_(ULONG, AddRef)(THIS) PURE;
391 STDMETHOD_(ULONG, Release)(THIS) PURE;
392 /*** ID3DXBaseMesh ***/
393 STDMETHOD(DrawSubset)(THIS_ DWORD attrib_id) PURE;
394 STDMETHOD_(DWORD, GetNumFaces)(THIS) PURE;
395 STDMETHOD_(DWORD, GetNumVertices)(THIS) PURE;
396 STDMETHOD_(DWORD, GetFVF)(THIS) PURE;
397 STDMETHOD(GetDeclaration)(THIS_ D3DVERTEXELEMENT9 declaration[MAX_FVF_DECL_SIZE]) PURE;
398 STDMETHOD_(DWORD, GetNumBytesPerVertex)(THIS) PURE;
399 STDMETHOD_(DWORD, GetOptions)(THIS) PURE;
400 STDMETHOD(GetDevice)(THIS_ struct IDirect3DDevice9 **device) PURE;
401 STDMETHOD(CloneMeshFVF)(THIS_ DWORD options, DWORD fvf,
402 struct IDirect3DDevice9 *device, struct ID3DXMesh **clone_mesh) PURE;
403 STDMETHOD(CloneMesh)(THIS_ DWORD options, const D3DVERTEXELEMENT9 *declaration,
404 struct IDirect3DDevice9 *device, struct ID3DXMesh **clone_mesh) PURE;
405 STDMETHOD(GetVertexBuffer)(THIS_ struct IDirect3DVertexBuffer9 **vertex_buffer) PURE;
406 STDMETHOD(GetIndexBuffer)(THIS_ struct IDirect3DIndexBuffer9 **index_buffer) PURE;
407 STDMETHOD(LockVertexBuffer)(THIS_ DWORD flags, void **data) PURE;
408 STDMETHOD(UnlockVertexBuffer)(THIS) PURE;
409 STDMETHOD(LockIndexBuffer)(THIS_ DWORD flags, void **data) PURE;
410 STDMETHOD(UnlockIndexBuffer)(THIS) PURE;
411 STDMETHOD(GetAttributeTable)(THIS_ D3DXATTRIBUTERANGE* attrib_table, DWORD* attrib_table_size) PURE;
412 STDMETHOD(ConvertPointRepsToAdjacency)(THIS_ const DWORD *point_reps, DWORD *adjacency) PURE;
413 STDMETHOD(ConvertAdjacencyToPointReps)(THIS_ const DWORD *adjacency, DWORD *point_reps) PURE;
414 STDMETHOD(GenerateAdjacency)(THIS_ FLOAT epsilon, DWORD* adjacency) PURE;
415 STDMETHOD(UpdateSemantics)(THIS_ D3DVERTEXELEMENT9 declaration[MAX_FVF_DECL_SIZE]) PURE;
416 /*** ID3DXPMesh ***/
417 STDMETHOD(ClonePMeshFVF)(THIS_ DWORD options, DWORD fvf,
418 struct IDirect3DDevice9 *device, struct ID3DXPMesh **clone_mesh) PURE;
419 STDMETHOD(ClonePMesh)(THIS_ DWORD options, const D3DVERTEXELEMENT9 *declaration,
420 struct IDirect3DDevice9 *device, struct ID3DXPMesh **clone_mesh) PURE;
421 STDMETHOD(SetNumFaces)(THIS_ DWORD faces) PURE;
422 STDMETHOD(SetNumVertices)(THIS_ DWORD vertices) PURE;
423 STDMETHOD_(DWORD, GetMaxFaces)(THIS) PURE;
424 STDMETHOD_(DWORD, GetMinFaces)(THIS) PURE;
425 STDMETHOD_(DWORD, GetMaxVertices)(THIS) PURE;
426 STDMETHOD_(DWORD, GetMinVertices)(THIS) PURE;
427 STDMETHOD(Save)(THIS_ IStream *stream, const D3DXMATERIAL *material,
428 const D3DXEFFECTINSTANCE *effect_instance, DWORD num_materials) PURE;
429 STDMETHOD(Optimize)(THIS_ DWORD flags, DWORD *adjacency_out, DWORD *face_remap,
430 ID3DXBuffer **vertex_remap, ID3DXMesh **opt_mesh) PURE;
431 STDMETHOD(OptimizeBaseLOD)(THIS_ DWORD flags, DWORD* face_remap) PURE;
432 STDMETHOD(TrimByFaces)(THIS_ DWORD new_faces_min, DWORD new_faces_max, DWORD* face_remap, DWORD* vertex_remap) PURE;
433 STDMETHOD(TrimByVertices)(THIS_ DWORD new_vertices_min, DWORD new_vertices_max, DWORD* face_remap, DWORD* vertex_remap) PURE;
434 STDMETHOD(GetAdjacency)(THIS_ DWORD* adjacency) PURE;
435 STDMETHOD(GenerateVertexHistory)(THIS_ DWORD* vertex_history) PURE;
436};
437#undef INTERFACE
438
439#define INTERFACE ID3DXSPMesh
440DECLARE_INTERFACE_(ID3DXSPMesh, IUnknown)
441{
442 /*** IUnknown methods ***/
443 STDMETHOD(QueryInterface)(THIS_ REFIID riid, void **out) PURE;
444 STDMETHOD_(ULONG, AddRef)(THIS) PURE;
445 STDMETHOD_(ULONG, Release)(THIS) PURE;
446 /*** ID3DXSPMesh ***/
447 STDMETHOD_(DWORD, GetNumFaces)(THIS) PURE;
448 STDMETHOD_(DWORD, GetNumVertices)(THIS) PURE;
449 STDMETHOD_(DWORD, GetNumFVF)(THIS) PURE;
450 STDMETHOD(GetDeclaration)(THIS_ D3DVERTEXELEMENT9 declaration[MAX_FVF_DECL_SIZE]) PURE;
451 STDMETHOD_(DWORD, GetOptions)(THIS) PURE;
452 STDMETHOD(GetDevice)(THIS_ struct IDirect3DDevice9 **device) PURE;
453 STDMETHOD(CloneMeshFVF)(THIS_ DWORD options, DWORD fvf,
454 struct IDirect3DDevice9 *device, DWORD *adjacency_out,
455 DWORD *vertex_remap_out, struct ID3DXMesh **clone_mesh) PURE;
456 STDMETHOD(CloneMesh)(THIS_ DWORD options, const D3DVERTEXELEMENT9 *declaration,
457 struct IDirect3DDevice9 *device, DWORD *adjacency_out,
458 DWORD *vertex_remap_out, struct ID3DXMesh **clone_mesh) PURE;
459 STDMETHOD(ClonePMeshFVF)(THIS_ DWORD options, DWORD fvf,
460 struct IDirect3DDevice9 *device, DWORD *vertex_remap_out,
461 float *errors_by_face, struct ID3DXPMesh **clone_mesh) PURE;
462 STDMETHOD(ClonePMesh)(THIS_ DWORD options, const D3DVERTEXELEMENT9 *declaration,
463 struct IDirect3DDevice9 *device, DWORD *vertex_remap_out,
464 float *errors_by_face, struct ID3DXPMesh **clone_mesh) PURE;
465 STDMETHOD(ReduceFaces)(THIS_ DWORD faces) PURE;
466 STDMETHOD(ReduceVertices)(THIS_ DWORD vertices) PURE;
467 STDMETHOD_(DWORD, GetMaxFaces)(THIS) PURE;
468 STDMETHOD_(DWORD, GetMaxVertices)(THIS) PURE;
469 STDMETHOD(GetVertexAttributeWeights)(THIS_ LPD3DXATTRIBUTEWEIGHTS vertex_attribute_weights) PURE;
470 STDMETHOD(GetVertexWeights)(THIS_ FLOAT* vertex_weights) PURE;
471};
472#undef INTERFACE
473
474#define INTERFACE ID3DXPatchMesh
475DECLARE_INTERFACE_(ID3DXPatchMesh, IUnknown)
476{
477 /*** IUnknown methods ***/
478 STDMETHOD(QueryInterface)(THIS_ REFIID riid, void **out) PURE;
479 STDMETHOD_(ULONG, AddRef)(THIS) PURE;
480 STDMETHOD_(ULONG, Release)(THIS) PURE;
481 /*** ID3DXPatchMesh ***/
482 STDMETHOD_(DWORD, GetNumPatches)(THIS) PURE;
483 STDMETHOD_(DWORD, GetNumVertices)(THIS) PURE;
484 STDMETHOD(GetDeclaration)(THIS_ D3DVERTEXELEMENT9 declaration[MAX_FVF_DECL_SIZE]) PURE;
485 STDMETHOD_(DWORD, GetControlVerticesPerPatch)(THIS) PURE;
486 STDMETHOD_(DWORD, GetOptions)(THIS) PURE;
487 STDMETHOD(GetDevice)(THIS_ struct IDirect3DDevice9 **device) PURE;
488 STDMETHOD(GetPatchInfo)(THIS_ LPD3DXPATCHINFO patch_info) PURE;
489 STDMETHOD(GetVertexBuffer)(THIS_ struct IDirect3DVertexBuffer9 **vertex_buffer) PURE;
490 STDMETHOD(GetIndexBuffer)(THIS_ struct IDirect3DIndexBuffer9 **index_buffer) PURE;
491 STDMETHOD(LockVertexBuffer)(THIS_ DWORD flags, void **data) PURE;
492 STDMETHOD(UnlockVertexBuffer)(THIS) PURE;
493 STDMETHOD(LockIndexBuffer)(THIS_ DWORD flags, void **data) PURE;
494 STDMETHOD(UnlockIndexBuffer)(THIS) PURE;
495 STDMETHOD(LockAttributeBuffer)(THIS_ DWORD flags, DWORD** data) PURE;
496 STDMETHOD(UnlockAttributeBuffer)(THIS) PURE;
497 STDMETHOD(GetTessSize)(THIS_ FLOAT tess_level, DWORD adaptive, DWORD* num_triangles, DWORD* num_vertices) PURE;
498 STDMETHOD(GenerateAdjacency)(THIS_ FLOAT tolerance) PURE;
499 STDMETHOD(CloneMesh)(THIS_ DWORD options, const D3DVERTEXELEMENT9 *declaration, ID3DXPatchMesh **clone_mesh) PURE;
500 STDMETHOD(Optimize)(THIS_ DWORD flags) PURE;
501 STDMETHOD(SetDisplaceParam)(THIS_ struct IDirect3DBaseTexture9 *texture, D3DTEXTUREFILTERTYPE min_filter,
502 D3DTEXTUREFILTERTYPE mag_filter, D3DTEXTUREFILTERTYPE mip_filter, D3DTEXTUREADDRESS wrap,
503 DWORD lod_bias) PURE;
504 STDMETHOD(GetDisplaceParam)(THIS_ struct IDirect3DBaseTexture9 **texture, D3DTEXTUREFILTERTYPE *min_filter,
505 D3DTEXTUREFILTERTYPE *mag_filter, D3DTEXTUREFILTERTYPE *mip_filter, D3DTEXTUREADDRESS *wrap,
506 DWORD *lod_bias) PURE;
507 STDMETHOD(Tessellate)(THIS_ float tess_level, ID3DXMesh *mesh) PURE;
508 STDMETHOD(TessellateAdaptive)(THIS_ const D3DXVECTOR4 *trans, DWORD max_tess_level,
509 DWORD min_tess_level, ID3DXMesh *mesh) PURE;
510};
511#undef INTERFACE
512
513#define INTERFACE ID3DXSkinInfo
514DECLARE_INTERFACE_(ID3DXSkinInfo, IUnknown)
515{
516 /*** IUnknown methods ***/
517 STDMETHOD(QueryInterface)(THIS_ REFIID riid, void **out) PURE;
518 STDMETHOD_(ULONG, AddRef)(THIS) PURE;
519 STDMETHOD_(ULONG, Release)(THIS) PURE;
520 /*** ID3DXSkinInfo ***/
521 STDMETHOD(SetBoneInfluence)(THIS_ DWORD bone, DWORD num_influences, const DWORD *vertices,
522 const FLOAT *weights) PURE;
523 STDMETHOD(SetBoneVertexInfluence)(THIS_ DWORD bone_num, DWORD influence_num, float weight) PURE;
524 STDMETHOD_(DWORD, GetNumBoneInfluences)(THIS_ DWORD bone) PURE;
525 STDMETHOD(GetBoneInfluence)(THIS_ DWORD bone, DWORD* vertices, FLOAT* weights) PURE;
526 STDMETHOD(GetBoneVertexInfluence)(THIS_ DWORD bone_num, DWORD influence_num, float *weight, DWORD* vertex_num) PURE;
527 STDMETHOD(GetMaxVertexInfluences)(THIS_ DWORD* max_vertex_influences) PURE;
528 STDMETHOD_(DWORD, GetNumBones)(THIS) PURE;
529 STDMETHOD(FindBoneVertexInfluenceIndex)(THIS_ DWORD bone_num, DWORD vertex_num, DWORD* influence_index) PURE;
530 STDMETHOD(GetMaxFaceInfluences)(THIS_ struct IDirect3DIndexBuffer9 *index_buffer,
531 DWORD num_faces, DWORD *max_face_influences) PURE;
532 STDMETHOD(SetMinBoneInfluence)(THIS_ FLOAT min_influence) PURE;
533 STDMETHOD_(FLOAT, GetMinBoneInfluence)(THIS) PURE;
534 STDMETHOD(SetBoneName)(THIS_ DWORD bone_idx, const char *name) PURE;
535 STDMETHOD_(const char *, GetBoneName)(THIS_ DWORD bone_idx) PURE;
536 STDMETHOD(SetBoneOffsetMatrix)(THIS_ DWORD bone, const D3DXMATRIX *bone_transform) PURE;
537 STDMETHOD_(D3DXMATRIX *, GetBoneOffsetMatrix)(THIS_ DWORD bone) PURE;
538 STDMETHOD(Clone)(THIS_ ID3DXSkinInfo **skin_info) PURE;
539 STDMETHOD(Remap)(THIS_ DWORD num_vertices, DWORD* vertex_remap) PURE;
540 STDMETHOD(SetFVF)(THIS_ DWORD FVF) PURE;
541 STDMETHOD(SetDeclaration)(THIS_ const D3DVERTEXELEMENT9 *declaration) PURE;
542 STDMETHOD_(DWORD, GetFVF)(THIS) PURE;
543 STDMETHOD(GetDeclaration)(THIS_ D3DVERTEXELEMENT9 declaration[MAX_FVF_DECL_SIZE]) PURE;
544 STDMETHOD(UpdateSkinnedMesh)(THIS_ const D3DXMATRIX *bone_transforms,
545 const D3DXMATRIX *bone_inv_transpose_transforms, const void *src_vertices, void *dst_vertices) PURE;
546 STDMETHOD(ConvertToBlendedMesh)(THIS_ ID3DXMesh *mesh_in, DWORD options, const DWORD *adjacency_in,
547 DWORD *adjacency_out, DWORD *face_remap, ID3DXBuffer **vertex_remap, DWORD *max_face_infl,
548 DWORD *num_bone_combinations, ID3DXBuffer **bone_combination_table, ID3DXMesh **mesh_out) PURE;
549 STDMETHOD(ConvertToIndexedBlendedMesh)(THIS_ ID3DXMesh *mesh_in, DWORD options, DWORD palette_size,
550 const DWORD *adjacency_in, DWORD *adjacency_out, DWORD *face_remap, ID3DXBuffer **vertex_remap,
551 DWORD *max_face_infl, DWORD *num_bone_combinations, ID3DXBuffer **bone_combination_table,
552 ID3DXMesh **mesh_out) PURE;
553};
554#undef INTERFACE
555
556#define INTERFACE ID3DXPRTBuffer
557DECLARE_INTERFACE_(ID3DXPRTBuffer, IUnknown)
558{
559 /*** IUnknown methods ***/
560 STDMETHOD(QueryInterface)(THIS_ REFIID riid, void **out) PURE;
561 STDMETHOD_(ULONG, AddRef)(THIS) PURE;
562 STDMETHOD_(ULONG, Release)(THIS) PURE;
563 /*** ID3DXPRTBuffer methods ***/
564 STDMETHOD_(UINT, GetNumSamples)(THIS) PURE;
565 STDMETHOD_(UINT, GetNumCoeffs)(THIS) PURE;
566 STDMETHOD_(UINT, GetNumChannels)(THIS) PURE;
567 STDMETHOD_(WINBOOL, IsTexture)(THIS) PURE;
568 STDMETHOD_(WINBOOL, GetWidth)(THIS) PURE;
569 STDMETHOD_(WINBOOL, GetHeight)(THIS) PURE;
570 STDMETHOD(Resize)(THIS_ UINT new_size) PURE;
571 STDMETHOD(LockBuffer)(THIS_ UINT start, UINT num_samples, FLOAT **data) PURE;
572 STDMETHOD(UnlockBuffer)(THIS) PURE;
573 STDMETHOD(ScaleBuffer)(THIS_ FLOAT scale) PURE;
574 STDMETHOD(AddBuffer)(THIS_ ID3DXPRTBuffer *buffer) PURE;
575 STDMETHOD(AttachGH)(THIS_ struct ID3DXTextureGutterHelper *gh) PURE;
576 STDMETHOD(ReleaseGH)(THIS) PURE;
577 STDMETHOD(EvalGH)(THIS) PURE;
578 STDMETHOD(ExtractTexture)(THIS_ UINT channel, UINT start_coefficient,
579 UINT num_coefficients, struct IDirect3DTexture9 *texture) PURE;
580 STDMETHOD(ExtractToMesh)(THIS_ UINT num_coefficients, D3DDECLUSAGE usage,
581 UINT usage_index_start, ID3DXMesh *scene) PURE;
582};
583#undef INTERFACE
584
585#define INTERFACE ID3DXPRTCompBuffer
586DECLARE_INTERFACE_(ID3DXPRTCompBuffer, IUnknown)
587{
588 /*** IUnknown methods ***/
589 STDMETHOD(QueryInterface)(THIS_ REFIID riid, void **out) PURE;
590 STDMETHOD_(ULONG, AddRef)(THIS) PURE;
591 STDMETHOD_(ULONG, Release)(THIS) PURE;
592 /*** ID3DXPRTCompBuffer methods ***/
593 STDMETHOD_(UINT, GetNumSamples)(THIS) PURE;
594 STDMETHOD_(UINT, GetNumCoeffs)(THIS) PURE;
595 STDMETHOD_(UINT, GetNumChannels)(THIS) PURE;
596 STDMETHOD_(WINBOOL, IsTexture)(THIS) PURE;
597 STDMETHOD_(UINT, GetWidth)(THIS) PURE;
598 STDMETHOD_(UINT, GetHeight)(THIS) PURE;
599 STDMETHOD_(UINT, GetNumClusters)(THIS) PURE;
600 STDMETHOD_(UINT, GetNumPCA)(THIS) PURE;
601 STDMETHOD(NormalizeData)(THIS) PURE;
602 STDMETHOD(ExtractBasis)(THIS_ UINT cluster, FLOAT *cluster_basis) PURE;
603 STDMETHOD(ExtractClusterIDs)(THIS_ UINT *cluster_ids) PURE;
604 STDMETHOD(ExtractPCA)(THIS_ UINT start_pca, UINT num_extract, FLOAT *pca_coefficients) PURE;
605 STDMETHOD(ExtractTexture)(THIS_ UINT start_pca, UINT num_pca, struct IDirect3DTexture9 *texture) PURE;
606 STDMETHOD(ExtractToMesh)(THIS_ UINT num_pca, D3DDECLUSAGE usage, UINT usage_index_start, ID3DXMesh *scene) PURE;
607};
608#undef INTERFACE
609
610#define INTERFACE ID3DXTextureGutterHelper
611DECLARE_INTERFACE_(ID3DXTextureGutterHelper, IUnknown)
612{
613 /*** IUnknown methods ***/
614 STDMETHOD(QueryInterface)(THIS_ REFIID riid, void **out) PURE;
615 STDMETHOD_(ULONG, AddRef)(THIS) PURE;
616 STDMETHOD_(ULONG, Release)(THIS) PURE;
617 /*** ID3DXTextureGutterHelper methods ***/
618 STDMETHOD_(UINT, GetWidth)(THIS) PURE;
619 STDMETHOD_(UINT, GetHeight)(THIS) PURE;
620
621 STDMETHOD(ApplyGuttersFloat)(THIS_ FLOAT *data_in, UINT num_coeffs, UINT width, UINT height) PURE;
622 STDMETHOD(ApplyGuttersTex)(THIS_ struct IDirect3DTexture9 *texture) PURE;
623 STDMETHOD(ApplyGuttersPRT)(THIS_ ID3DXPRTBuffer *buffer) PURE;
624 STDMETHOD(ResampleTex)(THIS_ struct IDirect3DTexture9 *texture_in, struct ID3DXMesh *mesh_in,
625 D3DDECLUSAGE usage, UINT usage_index, struct IDirect3DTexture9 *texture_out) PURE;
626 STDMETHOD(GetFaceMap)(THIS_ UINT *face_data) PURE;
627 STDMETHOD(GetBaryMap)(THIS_ D3DXVECTOR2 *bary_data) PURE;
628 STDMETHOD(GetTexelMap)(THIS_ D3DXVECTOR2 *texel_data) PURE;
629 STDMETHOD(GetGutterMap)(THIS_ BYTE *gutter_data) PURE;
630 STDMETHOD(SetFaceMap)(THIS_ UINT *face_data) PURE;
631 STDMETHOD(SetBaryMap)(THIS_ D3DXVECTOR2 *bary_data) PURE;
632 STDMETHOD(SetTexelMap)(THIS_ D3DXVECTOR2 *texel_data) PURE;
633 STDMETHOD(SetGutterMap)(THIS_ BYTE *gutter_data) PURE;
634};
635#undef INTERFACE
636
637#define INTERFACE ID3DXPRTEngine
638DECLARE_INTERFACE_(ID3DXPRTEngine, IUnknown)
639{
640 /*** IUnknown methods ***/
641 STDMETHOD(QueryInterface)(THIS_ REFIID riid, void **out) PURE;
642 STDMETHOD_(ULONG, AddRef)(THIS) PURE;
643 STDMETHOD_(ULONG, Release)(THIS) PURE;
644 /*** ID3DXPRTEngine methods ***/
645 STDMETHOD(SetMeshMaterials)(THIS_ const D3DXSHMATERIAL **materials, UINT num_meshes,
646 UINT num_channels, WINBOOL set_albedo, FLOAT length_scale) PURE;
647 STDMETHOD(SetPerVertexAlbedo)(THIS_ const void *data_in, UINT num_channels, UINT stride) PURE;
648 STDMETHOD(SetPerTexelAlbedo)(THIS_ struct IDirect3DTexture9 *albedo_texture,
649 UINT num_channels, struct ID3DXTextureGutterHelper *gh) PURE;
650 STDMETHOD(GetVertexAlbedo)(THIS_ D3DXCOLOR *vert_colors, UINT num_verts) PURE;
651 STDMETHOD(SetPerTexelNormals)(THIS_ struct IDirect3DTexture9 *normal_texture) PURE;
652 STDMETHOD(ExtractPerVertexAlbedo)(THIS_ ID3DXMesh *mesh, D3DDECLUSAGE usage, UINT num_channels) PURE;
653 STDMETHOD(ResampleBuffer)(THIS_ ID3DXPRTBuffer *buffer_in, ID3DXPRTBuffer *buffer_out) PURE;
654 STDMETHOD(GetAdaptedMesh)(THIS_ struct IDirect3DDevice9 *device, UINT *face_remap,
655 UINT *vert_remap, float *vert_weights, struct ID3DXMesh **mesh) PURE;
656 STDMETHOD_(UINT, GetNumVerts)(THIS) PURE;
657 STDMETHOD_(UINT, GetNumFaces)(THIS) PURE;
658 STDMETHOD(SetMinMaxIntersection)(THIS_ FLOAT min, FLOAT max) PURE;
659 STDMETHOD(RobustMeshRefine)(THIS_ FLOAT min_edge_length, UINT max_subdiv) PURE;
660 STDMETHOD(SetSamplingInfo)(THIS_ UINT num_rays, WINBOOL use_sphere,
661 WINBOOL use_cosine, WINBOOL adaptive, FLOAT adpative_thresh) PURE;
662 STDMETHOD(ComputeDirectLightingSH)(THIS_ UINT sh_order, ID3DXPRTBuffer *data_out) PURE;
663 STDMETHOD(ComputeDirectLightingSHAdaptive)(THIS_ UINT sh_order, float adaptive_thresh,
664 float min_edge_length, UINT max_subdiv, ID3DXPRTBuffer *data_out) PURE;
665 STDMETHOD(ComputeDirectLightingSHGPU)(THIS_ struct IDirect3DDevice9 *device, UINT flags,
666 UINT sh_order, float zbias, float zangle_bias, struct ID3DXPRTBuffer *data_out) PURE;
667 STDMETHOD(ComputeSS)(THIS_ ID3DXPRTBuffer *data_in, ID3DXPRTBuffer *data_out,
668 ID3DXPRTBuffer *data_total) PURE;
669 STDMETHOD(ComputeSSAdaptive)(THIS_ ID3DXPRTBuffer *data_in, float adaptive_thres,
670 float min_edge_length, UINT max_subdiv, ID3DXPRTBuffer *data_out, ID3DXPRTBuffer *data_total) PURE;
671 STDMETHOD(ComputeBounce)(THIS_ ID3DXPRTBuffer *data_in, ID3DXPRTBuffer *data_out,
672 ID3DXPRTBuffer *data_total) PURE;
673 STDMETHOD(ComputeBounceAdaptive)(THIS_ ID3DXPRTBuffer *data_in, float adaptive_thres,
674 float min_edge_length, UINT max_subdiv, ID3DXPRTBuffer *data_out, ID3DXPRTBuffer *data_total) PURE;
675 STDMETHOD(ComputeVolumeSamplesDirectSH)(THIS_ UINT sh_order_in, UINT sh_order_out,
676 UINT num_vol_samples, const D3DXVECTOR3 *sample_locs, ID3DXPRTBuffer *data_out) PURE;
677 STDMETHOD(ComputeVolumeSamples)(THIS_ ID3DXPRTBuffer *surf_data_in, UINT sh_order,
678 UINT num_vol_samples, const D3DXVECTOR3 *sample_locs, ID3DXPRTBuffer *data_out) PURE;
679 STDMETHOD(ComputeSurfSamplesDirectSH)(THIS_ UINT sh_order, UINT num_samples,
680 const D3DXVECTOR3 *sample_locs, const D3DXVECTOR3 *sample_norms, ID3DXPRTBuffer *data_out) PURE;
681 STDMETHOD(ComputeSurfSamplesBounce)(THIS_ ID3DXPRTBuffer *surf_data_in, UINT num_samples,
682 const D3DXVECTOR3 *sample_locs, const D3DXVECTOR3 *sample_norms, ID3DXPRTBuffer *data_out,
683 ID3DXPRTBuffer *data_total) PURE;
684 STDMETHOD(FreeSSData)(THIS) PURE;
685 STDMETHOD(FreeBounceData)(THIS) PURE;
686 STDMETHOD(ComputeLDPRTCoeffs)(THIS_ ID3DXPRTBuffer *data_in, UINT sh_order, D3DXVECTOR3 *norm_out,
687 ID3DXPRTBuffer *data_out) PURE;
688 STDMETHOD(ScaleMeshChunk)(THIS_ UINT mesh_chunk, float scale, ID3DXPRTBuffer *data_out) PURE;
689 STDMETHOD(MultiplyAlbedo)(THIS_ ID3DXPRTBuffer *data_out) PURE;
690 STDMETHOD(SetCallback)(THIS_ LPD3DXSHPRTSIMCB cb, float frequency, void *user_context) PURE;
691 STDMETHOD_(WINBOOL, ShadowRayIntersects)(THIS_ const D3DXVECTOR3 *ray_pos,
692 const D3DXVECTOR3 *ray_dir) PURE;
693 STDMETHOD_(WINBOOL, ClosestRayIntersects)(THIS_ const D3DXVECTOR3 *ray_pos,
694 const D3DXVECTOR3 *ray_dir, DWORD *face_index, FLOAT *u, FLOAT *v, FLOAT *dist) PURE;
695};
696#undef INTERFACE
697
698#ifdef __cplusplus
699extern "C" {
700#endif
701
702HRESULT WINAPI D3DXCreateMesh(DWORD face_count, DWORD vertex_count, DWORD flags,
703 const D3DVERTEXELEMENT9 *declaration, struct IDirect3DDevice9 *device, struct ID3DXMesh **mesh);
704HRESULT WINAPI D3DXCreateMeshFVF(DWORD face_count, DWORD vertex_count, DWORD flags,
705 DWORD fvf, struct IDirect3DDevice9 *device, struct ID3DXMesh **mesh);
706HRESULT WINAPI D3DXCreateBuffer(DWORD size, ID3DXBuffer **buffer);
707HRESULT WINAPI D3DXCreateSPMesh(ID3DXMesh *mesh, const DWORD *adjacency,
708 const D3DXATTRIBUTEWEIGHTS *attribute_weights, const float *vertex_weights, ID3DXSPMesh **spmesh);
709HRESULT WINAPI D3DXCreatePMeshFromStream(struct IStream *stream, DWORD flags, struct IDirect3DDevice9 *device,
710 struct ID3DXBuffer **materials, struct ID3DXBuffer **effect_instances,
711 DWORD *material_count, struct ID3DXPMesh **mesh);
712HRESULT WINAPI D3DXCreateSkinInfo(DWORD vertex_count, const D3DVERTEXELEMENT9 *declaration,
713 DWORD bone_count, ID3DXSkinInfo **skin_info);
714HRESULT WINAPI D3DXCreateSkinInfoFVF(DWORD vertex_count, DWORD fvf, DWORD bone_count, ID3DXSkinInfo **skin_info);
715HRESULT WINAPI D3DXCreateSkinInfoFromBlendedMesh(ID3DXBaseMesh *mesh, DWORD bone_count,
716 const D3DXBONECOMBINATION *bone_combination_table, ID3DXSkinInfo **skin_info);
717HRESULT WINAPI D3DXCreatePatchMesh(const D3DXPATCHINFO *patch_info, DWORD patch_count,
718 DWORD vertex_count, DWORD flags, const D3DVERTEXELEMENT9 *declaration,
719 struct IDirect3DDevice9 *device, struct ID3DXPatchMesh **mesh);
720HRESULT WINAPI D3DXCreatePRTBuffer(UINT sample_count, UINT coeff_count, UINT channel_count, ID3DXPRTBuffer **buffer);
721HRESULT WINAPI D3DXCreatePRTBufferTex(UINT width, UINT height, UINT coeff_count,
722 UINT channel_count, ID3DXPRTBuffer **buffer);
723HRESULT WINAPI D3DXCreatePRTCompBuffer(D3DXSHCOMPRESSQUALITYTYPE quality, UINT cluster_count, UINT pca_count,
724 LPD3DXSHPRTSIMCB cb, void *ctx, ID3DXPRTBuffer *input, ID3DXPRTCompBuffer **buffer);
725HRESULT WINAPI D3DXCreateTextureGutterHelper(UINT width, UINT height, ID3DXMesh *mesh,
726 float gutter_size, ID3DXTextureGutterHelper **gh);
727HRESULT WINAPI D3DXCreatePRTEngine(ID3DXMesh *mesh, DWORD *adjacency, WINBOOL extract_uv,
728 ID3DXMesh *blocker_mesh, ID3DXPRTEngine **engine);
729HRESULT WINAPI D3DXLoadMeshFromXA(const char *filename, DWORD flags, struct IDirect3DDevice9 *device,
730 struct ID3DXBuffer **adjacency, struct ID3DXBuffer **materials, struct ID3DXBuffer **effect_instances,
731 DWORD *material_count, struct ID3DXMesh **mesh);
732HRESULT WINAPI D3DXLoadMeshFromXW(const WCHAR *filename, DWORD flags, struct IDirect3DDevice9 *device,
733 struct ID3DXBuffer **adjacency, struct ID3DXBuffer **materials, struct ID3DXBuffer **effect_instances,
734 DWORD *material_count, struct ID3DXMesh **mesh);
735#define D3DXLoadMeshFromX __MINGW_NAME_AW(D3DXLoadMeshFromX)
736HRESULT WINAPI D3DXLoadMeshFromXInMemory(const void *data, DWORD data_size, DWORD flags,
737 struct IDirect3DDevice9 *device, struct ID3DXBuffer **adjacency, struct ID3DXBuffer **materials,
738 struct ID3DXBuffer **effect_instances, DWORD *material_count, struct ID3DXMesh **mesh);
739HRESULT WINAPI D3DXLoadMeshFromXResource(HMODULE module, const char *resource, const char *resource_type,
740 DWORD flags, struct IDirect3DDevice9 *device, struct ID3DXBuffer **adjacency,
741 struct ID3DXBuffer **materials, struct ID3DXBuffer **effect_instances,
742 DWORD *material_count, struct ID3DXMesh **mesh);
743HRESULT WINAPI D3DXLoadMeshFromXof(struct ID3DXFileData *file_data, DWORD flags, struct IDirect3DDevice9 *device,
744 struct ID3DXBuffer **adjacency, struct ID3DXBuffer **materials, struct ID3DXBuffer **effect_instances,
745 DWORD *material_count, struct ID3DXMesh **mesh);
746HRESULT WINAPI D3DXLoadPatchMeshFromXof(struct ID3DXFileData *file_data, DWORD flags, struct IDirect3DDevice9 *device,
747 struct ID3DXBuffer **adjacency, struct ID3DXBuffer **materials, struct ID3DXBuffer **effect_instances,
748 DWORD *material_count, struct ID3DXPatchMesh **mesh);
749HRESULT WINAPI D3DXLoadSkinMeshFromXof(struct ID3DXFileData *file_data, DWORD flags, struct IDirect3DDevice9 *device,
750 struct ID3DXBuffer **adjacency, struct ID3DXBuffer **materials, struct ID3DXBuffer **effect_instances,
751 DWORD *material_count, struct ID3DXSkinInfo **skin_info, struct ID3DXMesh **mesh);
752HRESULT WINAPI D3DXLoadPRTBufferFromFileA(const char *filename, ID3DXPRTBuffer **buffer);
753HRESULT WINAPI D3DXLoadPRTBufferFromFileW(const WCHAR *filename, ID3DXPRTBuffer **buffer);
754#define D3DXLoadPRTBufferFromFile __MINGW_NAME_AW(D3DXLoadPRTBufferFromFile)
755HRESULT WINAPI D3DXLoadPRTCompBufferFromFileA(const char *filename, ID3DXPRTCompBuffer **buffer);
756HRESULT WINAPI D3DXLoadPRTCompBufferFromFileW(const WCHAR *filename, ID3DXPRTCompBuffer **buffer);
757#define D3DXLoadPRTCompBufferFromFile __MINGW_NAME_AW(D3DXLoadPRTCompBufferFromFile)
758HRESULT WINAPI D3DXSaveMeshToXA(const char *filename, ID3DXMesh *mesh, const DWORD *adjacency,
759 const D3DXMATERIAL *materials, const D3DXEFFECTINSTANCE *effect_instances, DWORD material_count, DWORD format);
760HRESULT WINAPI D3DXSaveMeshToXW(const WCHAR *filename, ID3DXMesh *mesh, const DWORD *adjacency,
761 const D3DXMATERIAL *materials, const D3DXEFFECTINSTANCE *effect_instances, DWORD material_count, DWORD format);
762#define D3DXSaveMeshToX __MINGW_NAME_AW(D3DXSaveMeshToX)
763HRESULT WINAPI D3DXSavePRTBufferToFileA(const char *filename, ID3DXPRTBuffer *buffer);
764HRESULT WINAPI D3DXSavePRTBufferToFileW(const WCHAR *filename, ID3DXPRTBuffer *buffer);
765#define D3DXSavePRTBufferToFile __MINGW_NAME_AW(D3DXSavePRTBufferToFile)
766HRESULT WINAPI D3DXSavePRTCompBufferToFileA(const char *filename, ID3DXPRTCompBuffer *buffer);
767HRESULT WINAPI D3DXSavePRTCompBufferToFileW(const WCHAR *filename, ID3DXPRTCompBuffer *buffer);
768#define D3DXSavePRTCompBufferToFile __MINGW_NAME_AW(D3DXSavePRTCompBufferToFile)
769UINT WINAPI D3DXGetDeclLength(const D3DVERTEXELEMENT9 *decl);
770UINT WINAPI D3DXGetDeclVertexSize(const D3DVERTEXELEMENT9 *decl, DWORD stream_idx);
771UINT WINAPI D3DXGetFVFVertexSize(DWORD);
772WINBOOL WINAPI D3DXBoxBoundProbe(const D3DXVECTOR3 *vmin, const D3DXVECTOR3 *vmax,
773 const D3DXVECTOR3 *ray_pos, const D3DXVECTOR3 *ray_dir);
774WINBOOL WINAPI D3DXSphereBoundProbe(const D3DXVECTOR3 *center, FLOAT radius,
775 const D3DXVECTOR3 *ray_pos, const D3DXVECTOR3 *ray_dir);
776HRESULT WINAPI D3DXCleanMesh(D3DXCLEANTYPE clean_type, ID3DXMesh *mesh_in, const DWORD *adjacency_in,
777 ID3DXMesh **mesh_out, DWORD *adjacency_out, ID3DXBuffer **errors);
778HRESULT WINAPI D3DXConcatenateMeshes(struct ID3DXMesh **meshes, UINT mesh_count, DWORD flags,
779 const D3DXMATRIX *geometry_matrices, const D3DXMATRIX *texture_matrices,
780 const D3DVERTEXELEMENT9 *declaration, struct IDirect3DDevice9 *device, struct ID3DXMesh **mesh);
781HRESULT WINAPI D3DXComputeBoundingBox(const D3DXVECTOR3 *first_pos, DWORD num_vertices,
782 DWORD stride, D3DXVECTOR3 *vmin, D3DXVECTOR3 *vmax);
783HRESULT WINAPI D3DXComputeBoundingSphere(const D3DXVECTOR3 *first_pos, DWORD num_vertices,
784 DWORD stride, D3DXVECTOR3 *center, FLOAT *radius);
785HRESULT WINAPI D3DXComputeIMTFromPerTexelSignal(ID3DXMesh *mesh, DWORD texture_idx, float *texel_signal,
786 UINT width, UINT height, UINT signal_dimension, UINT component_count, DWORD flags,
787 LPD3DXUVATLASCB cb, void *ctx, ID3DXBuffer **buffer);
788HRESULT WINAPI D3DXComputeIMTFromPerVertexSignal(ID3DXMesh *mesh, const float *vertex_signal,
789 UINT signal_dimension, UINT signal_stride, DWORD flags,
790 LPD3DXUVATLASCB cb, void *ctx, ID3DXBuffer **buffer);
791HRESULT WINAPI D3DXComputeIMTFromSignal(ID3DXMesh *mesh, DWORD texture_idx, UINT signal_dimension,
792 float max_uv_distance, DWORD flags, LPD3DXIMTSIGNALCALLBACK signal_cb, void *signal_ctx,
793 LPD3DXUVATLASCB status_cb, void *status_ctx, ID3DXBuffer **buffer);
794HRESULT WINAPI D3DXComputeIMTFromTexture(struct ID3DXMesh *mesh, struct IDirect3DTexture9 *texture,
795 DWORD texture_idx, DWORD options, LPD3DXUVATLASCB cb, void *ctx, struct ID3DXBuffer **out);
796HRESULT WINAPI D3DXComputeNormals(ID3DXBaseMesh *mesh, const DWORD *adjacency);
797HRESULT WINAPI D3DXComputeTangentFrameEx(ID3DXMesh *mesh_in, DWORD texture_in_semantic, DWORD texture_in_idx,
798 DWORD u_partial_out_semantic, DWORD u_partial_out_idx, DWORD v_partial_out_semantic,
799 DWORD v_partial_out_idx, DWORD normal_out_semantic, DWORD normal_out_idx, DWORD flags,
800 const DWORD *adjacency, float partial_edge_threshold, float singular_point_threshold,
801 float normal_edge_threshold, ID3DXMesh **mesh_out, ID3DXBuffer **buffer);
802HRESULT WINAPI D3DXComputeTangent(ID3DXMesh *mesh, DWORD stage, DWORD tangent_idx,
803 DWORD binorm_idx, DWORD wrap, const DWORD *adjacency);
804HRESULT WINAPI D3DXConvertMeshSubsetToSingleStrip(struct ID3DXBaseMesh *mesh_in, DWORD attribute_id,
805 DWORD ib_flags, struct IDirect3DIndexBuffer9 **index_buffer, DWORD *index_count);
806HRESULT WINAPI D3DXConvertMeshSubsetToStrips(struct ID3DXBaseMesh *mesh_in, DWORD attribute_id,
807 DWORD ib_flags, struct IDirect3DIndexBuffer9 **index_buffer, DWORD *index_count,
808 struct ID3DXBuffer **strip_lengths, DWORD *strip_count);
809HRESULT WINAPI D3DXDeclaratorFromFVF(DWORD, D3DVERTEXELEMENT9[MAX_FVF_DECL_SIZE]);
810HRESULT WINAPI D3DXFVFFromDeclarator(const D3DVERTEXELEMENT9 *decl, DWORD *fvf);
811HRESULT WINAPI D3DXGenerateOutputDecl(D3DVERTEXELEMENT9 *decl_out, const D3DVERTEXELEMENT9 *decl_in);
812HRESULT WINAPI D3DXGeneratePMesh(ID3DXMesh *mesh, const DWORD *adjacency,
813 const D3DXATTRIBUTEWEIGHTS *attribute_weights, const float *vertex_weights,
814 DWORD min_value, DWORD flags, ID3DXPMesh **pmesh);
815HRESULT WINAPI D3DXIntersect(ID3DXBaseMesh *mesh, const D3DXVECTOR3 *ray_position, const D3DXVECTOR3 *ray_direction,
816 WINBOOL *hit, DWORD *face_idx, float *u, float *v, float *distance, ID3DXBuffer **hits, DWORD *hit_count);
817HRESULT WINAPI D3DXIntersectSubset(ID3DXBaseMesh *mesh, DWORD attribute_id, const D3DXVECTOR3 *ray_position,
818 const D3DXVECTOR3 *ray_direction, WINBOOL *hit, DWORD *face_idx, float *u, float *v, float *distance,
819 ID3DXBuffer **hits, DWORD *hit_count);
820WINBOOL WINAPI D3DXIntersectTri(const D3DXVECTOR3 *vtx0, const D3DXVECTOR3 *vtx1,
821 const D3DXVECTOR3 *vtx2, const D3DXVECTOR3 *ray_pos, const D3DXVECTOR3 *ray_dir, FLOAT *u,
822 FLOAT *v, FLOAT *dist);
823HRESULT WINAPI D3DXOptimizeFaces(const void *indices, UINT face_count,
824 UINT vertex_count, WINBOOL idx_32bit, DWORD *face_remap);
825HRESULT WINAPI D3DXOptimizeVertices(const void *indices, UINT face_count,
826 UINT vertex_count, WINBOOL idx_32bit, DWORD *vertex_remap);
827HRESULT WINAPI D3DXRectPatchSize(const FLOAT *segment_count, DWORD *num_triangles,
828 DWORD *num_vertices);
829HRESULT WINAPI D3DXSHPRTCompSuperCluster(UINT *cluster_ids, ID3DXMesh *scene, UINT max_cluster_count,
830 UINT cluster_count, UINT *scluster_ids, UINT *scluster_count);
831HRESULT WINAPI D3DXSHPRTCompSplitMeshSC(UINT *cluster_idx, UINT vertex_count, UINT cluster_count, UINT *scluster_ids,
832 UINT scluster_count, void *index_buffer_in, WINBOOL ib_in_32bit, UINT face_count, ID3DXBuffer **index_buffer_out,
833 UINT *index_buffer_size, WINBOOL ib_out_32bit, ID3DXBuffer **face_remap, ID3DXBuffer **vertex_data,
834 UINT *vertex_data_length, UINT *sc_cluster_list, D3DXSHPRTSPLITMESHCLUSTERDATA *sc_data);
835HRESULT WINAPI D3DXSimplifyMesh(ID3DXMesh *mesh_in, const DWORD *adjacency,
836 const D3DXATTRIBUTEWEIGHTS *attribute_weights, const float *vertex_weights, DWORD min_value,
837 DWORD flags, ID3DXMesh **mesh_out);
838HRESULT WINAPI D3DXSplitMesh(ID3DXMesh *mesh_in, const DWORD *adjacency_in, const DWORD max_size,
839 const DWORD flags, DWORD *mesh_out_count, ID3DXBuffer **mesh_out, ID3DXBuffer **adjacency_out,
840 ID3DXBuffer **face_remap_out, ID3DXBuffer **vertex_remap_out);
841HRESULT WINAPI D3DXTessellateNPatches(ID3DXMesh *mesh_in, const DWORD *adjacency_in, float segment_count,
842 WINBOOL quad_interp, ID3DXMesh **mesh_out, ID3DXBuffer **adjacency_out);
843HRESULT WINAPI D3DXTessellateRectPatch(struct IDirect3DVertexBuffer9 *buffer, const float *segment_count,
844 const D3DVERTEXELEMENT9 *declaration, const D3DRECTPATCH_INFO *patch_info, struct ID3DXMesh *mesh);
845HRESULT WINAPI D3DXTessellateTriPatch(struct IDirect3DVertexBuffer9 *buffer, const float *segment_count,
846 const D3DVERTEXELEMENT9 *declaration, const D3DTRIPATCH_INFO *patch_info, struct ID3DXMesh *mesh);
847HRESULT WINAPI D3DXTriPatchSize(const FLOAT *segment_count, DWORD *num_triangles,
848 DWORD *num_vertices);
849HRESULT WINAPI D3DXUVAtlasCreate(ID3DXMesh *mesh_in, UINT max_chart_count, float max_stretch_in,
850 UINT width, UINT height, float gutter, DWORD texture_idx, const DWORD *adjacency, const DWORD *false_edges,
851 const float *imt_array, LPD3DXUVATLASCB cb, float cb_freq, void *ctx, DWORD flags, ID3DXMesh **mesh_out,
852 ID3DXBuffer **face_partitioning_out, ID3DXBuffer **vertex_remap_out, float *max_stretch_out, UINT *chart_count);
853HRESULT WINAPI D3DXUVAtlasPack(ID3DXMesh *mesh, UINT width, UINT height, float gutter, DWORD texture_idx,
854 const DWORD *partition_result_adjacency, LPD3DXUVATLASCB cb, float cb_freq, void *ctx, DWORD flags,
855 ID3DXBuffer *face_partitioning);
856HRESULT WINAPI D3DXUVAtlasPartition(ID3DXMesh *mesh_in, UINT max_chart_count, float max_stretch_in,
857 DWORD texture_idx, const DWORD *adjacency, const DWORD *false_edges, const float *imt_array,
858 LPD3DXUVATLASCB cb, float cb_freq, void *ctx, DWORD flags, ID3DXMesh **mesh_out,
859 ID3DXBuffer **face_partitioning_out, ID3DXBuffer **vertex_remap_out, ID3DXBuffer **adjacency_out,
860 float *max_stretch_out, UINT *chart_count);
861HRESULT WINAPI D3DXValidMesh(ID3DXMesh *mesh, const DWORD *adjacency, ID3DXBuffer **errors);
862HRESULT WINAPI D3DXValidPatchMesh(ID3DXPatchMesh *mesh, DWORD *degenerate_vertex_count,
863 DWORD *degenerate_patch_count, ID3DXBuffer **errors);
864HRESULT WINAPI D3DXWeldVertices(ID3DXMesh *mesh, DWORD flags, const D3DXWELDEPSILONS *epsilons,
865 const DWORD *adjacency_in, DWORD *adjacency_out, DWORD *face_remap_out, ID3DXBuffer **vertex_remap_out);
866
867#ifdef __cplusplus
868}
869#endif
870
871DEFINE_GUID(DXFILEOBJ_XSkinMeshHeader, 0x3cf169ce, 0xff7c, 0x44ab, 0x93, 0xc0, 0xf7, 0x8f, 0x62, 0xd1, 0x72, 0xe2);
872DEFINE_GUID(DXFILEOBJ_VertexDuplicationIndices, 0xb8d65549, 0xd7c9, 0x4995, 0x89, 0xcf, 0x53, 0xa9, 0xa8, 0xb0, 0x31, 0xe3);
873DEFINE_GUID(DXFILEOBJ_FaceAdjacency, 0xa64c844a, 0xe282, 0x4756, 0x8b, 0x80, 0x25, 0x0c, 0xde, 0x04, 0x39, 0x8c);
874DEFINE_GUID(DXFILEOBJ_SkinWeights, 0x6f0d123b, 0xbad2, 0x4167, 0xa0, 0xd0, 0x80, 0x22, 0x4f, 0x25, 0xfa, 0xbb);
875DEFINE_GUID(DXFILEOBJ_Patch, 0xa3eb5d44, 0xfc22, 0x429d, 0x9a, 0xfb, 0x32, 0x21, 0xcb, 0x97, 0x19, 0xa6);
876DEFINE_GUID(DXFILEOBJ_PatchMesh, 0xd02c95cc, 0xedba, 0x4305, 0x9b, 0x5d, 0x18, 0x20, 0xd7, 0x70, 0x4d, 0xbf);
877DEFINE_GUID(DXFILEOBJ_PatchMesh9, 0xb9ec94e1, 0xb9a6, 0x4251, 0xba, 0x18, 0x94, 0x89, 0x3f, 0x02, 0xc0, 0xea);
878DEFINE_GUID(DXFILEOBJ_PMInfo, 0xb6c3e656, 0xec8b, 0x4b92, 0x9b, 0x62, 0x68, 0x16, 0x59, 0x52, 0x29, 0x47);
879DEFINE_GUID(DXFILEOBJ_PMAttributeRange, 0x917e0427, 0xc61e, 0x4a14, 0x9c, 0x64, 0xaf, 0xe6, 0x5f, 0x9e, 0x98, 0x44);
880DEFINE_GUID(DXFILEOBJ_PMVSplitRecord, 0x574ccc14, 0xf0b3, 0x4333, 0x82, 0x2d, 0x93, 0xe8, 0xa8, 0xa0, 0x8e, 0x4c);
881DEFINE_GUID(DXFILEOBJ_FVFData, 0xb6e70a0e, 0x8ef9, 0x4e83, 0x94, 0xad, 0xec, 0xc8, 0xb0, 0xc0, 0x48, 0x97);
882DEFINE_GUID(DXFILEOBJ_VertexElement, 0xf752461c, 0x1e23, 0x48f6, 0xb9, 0xf8, 0x83, 0x50, 0x85, 0x0f, 0x33, 0x6f);
883DEFINE_GUID(DXFILEOBJ_DeclData, 0xbf22e553, 0x292c, 0x4781, 0x9f, 0xea, 0x62, 0xbd, 0x55, 0x4b, 0xdd, 0x93);
884DEFINE_GUID(DXFILEOBJ_EffectFloats, 0xf1cfe2b3, 0x0de3, 0x4e28, 0xaf, 0xa1, 0x15, 0x5a, 0x75, 0x0a, 0x28, 0x2d);
885DEFINE_GUID(DXFILEOBJ_EffectString, 0xd55b097e, 0xbdb6, 0x4c52, 0xb0, 0x3d, 0x60, 0x51, 0xc8, 0x9d, 0x0e, 0x42);
886DEFINE_GUID(DXFILEOBJ_EffectDWord, 0x622c0ed0, 0x956e, 0x4da9, 0x90, 0x8a, 0x2a, 0xf9, 0x4f, 0x3c, 0xe7, 0x16);
887DEFINE_GUID(DXFILEOBJ_EffectParamFloats, 0x3014b9a0, 0x62f5, 0x478c, 0x9b, 0x86, 0xe4, 0xac, 0x9f, 0x4e, 0x41, 0x8b);
888DEFINE_GUID(DXFILEOBJ_EffectParamString, 0x1dbc4c88, 0x94c1, 0x46ee, 0x90, 0x76, 0x2c, 0x28, 0x81, 0x8c, 0x94, 0x81);
889DEFINE_GUID(DXFILEOBJ_EffectParamDWord, 0xe13963bc, 0xae51, 0x4c5d, 0xb0, 0x0f, 0xcf, 0xa3, 0xa9, 0xd9, 0x7c, 0xe5);
890DEFINE_GUID(DXFILEOBJ_EffectInstance, 0xe331f7e4, 0x0559, 0x4cc2, 0x8e, 0x99, 0x1c, 0xec, 0x16, 0x57, 0x92, 0x8f);
891DEFINE_GUID(DXFILEOBJ_AnimTicksPerSecond, 0x9e415a43, 0x7ba6, 0x4a73, 0x87, 0x43, 0xb7, 0x3d, 0x47, 0xe8, 0x84, 0x76);
892DEFINE_GUID(DXFILEOBJ_CompressedAnimationSet, 0x7f9b00b3, 0xf125, 0x4890, 0x87, 0x6e, 0x1c, 0x42, 0xbf, 0x69, 0x7c, 0x4d);
893
894#define XSKINEXP_TEMPLATES \
895 "xof 0303txt 0032\
896 template XSkinMeshHeader \
897 { \
898 <3CF169CE-FF7C-44ab-93C0-F78F62D172E2> \
899 WORD nMaxSkinWeightsPerVertex; \
900 WORD nMaxSkinWeightsPerFace; \
901 WORD nBones; \
902 } \
903 template VertexDuplicationIndices \
904 { \
905 <B8D65549-D7C9-4995-89CF-53A9A8B031E3> \
906 DWORD nIndices; \
907 DWORD nOriginalVertices; \
908 array DWORD indices[nIndices]; \
909 } \
910 template FaceAdjacency \
911 { \
912 <A64C844A-E282-4756-8B80-250CDE04398C> \
913 DWORD nIndices; \
914 array DWORD indices[nIndices]; \
915 } \
916 template SkinWeights \
917 { \
918 <6F0D123B-BAD2-4167-A0D0-80224F25FABB> \
919 STRING transformNodeName; \
920 DWORD nWeights; \
921 array DWORD vertexIndices[nWeights]; \
922 array float weights[nWeights]; \
923 Matrix4x4 matrixOffset; \
924 } \
925 template Patch \
926 { \
927 <A3EB5D44-FC22-429D-9AFB-3221CB9719A6> \
928 DWORD nControlIndices; \
929 array DWORD controlIndices[nControlIndices]; \
930 } \
931 template PatchMesh \
932 { \
933 <D02C95CC-EDBA-4305-9B5D-1820D7704BBF> \
934 DWORD nVertices; \
935 array Vector vertices[nVertices]; \
936 DWORD nPatches; \
937 array Patch patches[nPatches]; \
938 [ ... ] \
939 } \
940 template PatchMesh9 \
941 { \
942 <B9EC94E1-B9A6-4251-BA18-94893F02C0EA> \
943 DWORD Type; \
944 DWORD Degree; \
945 DWORD Basis; \
946 DWORD nVertices; \
947 array Vector vertices[nVertices]; \
948 DWORD nPatches; \
949 array Patch patches[nPatches]; \
950 [ ... ] \
951 } template EffectFloats \
952 { \
953 <F1CFE2B3-0DE3-4e28-AFA1-155A750A282D> \
954 DWORD nFloats; \
955 array float Floats[nFloats]; \
956 } \
957 template EffectString \
958 { \
959 <D55B097E-BDB6-4c52-B03D-6051C89D0E42> \
960 STRING Value; \
961 } \
962 template EffectDWord \
963 { \
964 <622C0ED0-956E-4da9-908A-2AF94F3CE716> \
965 DWORD Value; \
966 } template EffectParamFloats \
967 { \
968 <3014B9A0-62F5-478c-9B86-E4AC9F4E418B> \
969 STRING ParamName; \
970 DWORD nFloats; \
971 array float Floats[nFloats]; \
972 } template EffectParamString \
973 { \
974 <1DBC4C88-94C1-46ee-9076-2C28818C9481> \
975 STRING ParamName; \
976 STRING Value; \
977 } \
978 template EffectParamDWord \
979 { \
980 <E13963BC-AE51-4c5d-B00F-CFA3A9D97CE5> \
981 STRING ParamName; \
982 DWORD Value; \
983 } \
984 template EffectInstance \
985 { \
986 <E331F7E4-0559-4cc2-8E99-1CEC1657928F> \
987 STRING EffectFilename; \
988 [ ... ] \
989 } template AnimTicksPerSecond \
990 { \
991 <9E415A43-7BA6-4a73-8743-B73D47E88476> \
992 DWORD AnimTicksPerSecond; \
993 } \
994 template CompressedAnimationSet \
995 { \
996 <7F9B00B3-F125-4890-876E-1C42BF697C4D> \
997 DWORD CompressedBlockSize; \
998 FLOAT TicksPerSec; \
999 DWORD PlaybackType; \
1000 DWORD BufferLength; \
1001 array DWORD CompressedData[BufferLength]; \
1002 } "
1003
1004#define XEXTENSIONS_TEMPLATES \
1005 "xof 0303txt 0032\
1006 template FVFData \
1007 { \
1008 <B6E70A0E-8EF9-4e83-94AD-ECC8B0C04897> \
1009 DWORD dwFVF; \
1010 DWORD nDWords; \
1011 array DWORD data[nDWords]; \
1012 } \
1013 template VertexElement \
1014 { \
1015 <F752461C-1E23-48f6-B9F8-8350850F336F> \
1016 DWORD Type; \
1017 DWORD Method; \
1018 DWORD Usage; \
1019 DWORD UsageIndex; \
1020 } \
1021 template DeclData \
1022 { \
1023 <BF22E553-292C-4781-9FEA-62BD554BDD93> \
1024 DWORD nElements; \
1025 array VertexElement Elements[nElements]; \
1026 DWORD nDWords; \
1027 array DWORD data[nDWords]; \
1028 } \
1029 template PMAttributeRange \
1030 { \
1031 <917E0427-C61E-4a14-9C64-AFE65F9E9844> \
1032 DWORD iFaceOffset; \
1033 DWORD nFacesMin; \
1034 DWORD nFacesMax; \
1035 DWORD iVertexOffset; \
1036 DWORD nVerticesMin; \
1037 DWORD nVerticesMax; \
1038 } \
1039 template PMVSplitRecord \
1040 { \
1041 <574CCC14-F0B3-4333-822D-93E8A8A08E4C> \
1042 DWORD iFaceCLW; \
1043 DWORD iVlrOffset; \
1044 DWORD iCode; \
1045 } \
1046 template PMInfo \
1047 { \
1048 <B6C3E656-EC8B-4b92-9B62-681659522947> \
1049 DWORD nAttributes; \
1050 array PMAttributeRange attributeRanges[nAttributes]; \
1051 DWORD nMaxValence; \
1052 DWORD nMinLogicalVertices; \
1053 DWORD nMaxLogicalVertices; \
1054 DWORD nVSplits; \
1055 array PMVSplitRecord splitRecords[nVSplits]; \
1056 DWORD nAttributeMispredicts; \
1057 array DWORD attributeMispredicts[nAttributeMispredicts]; \
1058 } "
1059
1060#endif /* __WINE_D3DX9MESH_H */
Note: See TracBrowser for help on using the repository browser.