Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

677 lines
27 KiB

  1. //-------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. //
  5. // Copyright (C) Microsoft Corporation, 1998 - 1998
  6. //
  7. // File: D3DX8obj.h
  8. //
  9. //--------------------------------------------------------------------------
  10. #include "resource.h"
  11. class C_dxj_D3DX8Object :
  12. public I_dxj_D3DX8,
  13. public CComCoClass<C_dxj_D3DX8Object, &CLSID_D3DX8>,
  14. public CComObjectRoot
  15. {
  16. public:
  17. DECLARE_REGISTRY(CLSID_D3DX8, "DIRECT.D3DX8.0", "DIRECT.D3DX8.0", IDS_D3DX8_DESC, THREADFLAGS_BOTH)
  18. BEGIN_COM_MAP(C_dxj_D3DX8Object)
  19. COM_INTERFACE_ENTRY( I_dxj_D3DX8)
  20. END_COM_MAP()
  21. public:
  22. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateFont(
  23. /* [in] */ IUnknown *Device,
  24. #ifdef _WIN64
  25. /* [in] */ HANDLE hFont,
  26. #else
  27. /* [in] */ long hFont,
  28. #endif
  29. /* [retval][out] */ D3DXFont **retFont);
  30. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE DrawText(
  31. /* [in] */ D3DXFont *d3dFont,
  32. /* [in] */ long Color,
  33. /* [in] */ BSTR TextString,
  34. /* [in] */ RECT *Rect,
  35. /* [in] */ long Format);
  36. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE GetFVFVertexSize(
  37. /* [in] */ long FVF,
  38. /* [retval][out] */ long *size);
  39. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE AssembleShaderFromFile(
  40. /* [in] */ BSTR SrcFile,
  41. /* [in] */ long Flags,
  42. /* [in] */ BSTR *ErrLog,
  43. /* [out][in] */ D3DXBuffer **Constants,
  44. /* [retval][out] */ D3DXBuffer **ppVertexShader);
  45. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE AssembleShader(
  46. /* [in] */ BSTR SrcData,
  47. /* [in] */ long Flags,
  48. /* [out][in] */ D3DXBuffer **Constants,
  49. /* [in][out][optional] */ BSTR *ErrLog,
  50. /* [retval][out] */ D3DXBuffer **ppVertexShader);
  51. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE GetErrorString(
  52. /* [in] */ long hr,
  53. /* [retval][out] */ BSTR *retStr);
  54. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE LoadSurfaceFromFile(
  55. /* [in] */ IUnknown *DestSurface,
  56. /* [in] */ void *DestPalette,
  57. /* [in] */ void *DestRect,
  58. /* [in] */ BSTR SrcFile,
  59. /* [in] */ void *SrcRect,
  60. /* [in] */ long Filter,
  61. /* [in] */ long ColorKey,
  62. /* [in] */ void *SrcInfo);
  63. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE LoadSurfaceFromFileInMemory(
  64. /* [in] */ IUnknown *DestSurface,
  65. /* [in] */ void *DestPalette,
  66. /* [in] */ void *DestRect,
  67. /* [in] */ void *SrcData,
  68. /* [in] */ long LengthInBytes,
  69. /* [in] */ void *SrcRect,
  70. /* [in] */ long Filter,
  71. /* [in] */ long ColorKey,
  72. /* [in] */ void *SrcInfo);
  73. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE LoadSurfaceFromSurface(
  74. /* [in] */ IUnknown *DestSurface,
  75. /* [in] */ void *DestPalette,
  76. /* [in] */ void *DestRect,
  77. /* [in] */ IUnknown *SrcSurface,
  78. /* [in] */ void *SrcPalette,
  79. /* [in] */ void *SrcRect,
  80. /* [in] */ long Filter,
  81. /* [in] */ long ColorKey);
  82. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE LoadSurfaceFromMemory(
  83. /* [in] */ IUnknown *DestSurface,
  84. /* [in] */ void *DestPalette,
  85. /* [in] */ void *DestRect,
  86. /* [in] */ void *SrcData,
  87. /* [in] */ long formatSrc,
  88. /* [in] */ long SrcPitch,
  89. /* [in] */ void *SrcPalette,
  90. /* [in] */ RECT_CDESC *SrcRect,
  91. /* [in] */ long Filter,
  92. /* [in] */ long ColorKey);
  93. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CheckTextureRequirements(
  94. /* [out][in] */ IUnknown *Device,
  95. /* [out][in] */ long *Width,
  96. /* [out][in] */ long *Height,
  97. /* [out][in] */ long *NumMipLevels,
  98. /* [in] */ long Usage,
  99. /* [out][in] */ long *PixelFormat,
  100. /* [in] */ long Pool);
  101. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateTexture(
  102. /* [in] */ IUnknown *Device,
  103. /* [in] */ long Width,
  104. /* [in] */ long Height,
  105. /* [in] */ long MipLevels,
  106. /* [in] */ long Usage,
  107. /* [in] */ long PixelFormat,
  108. /* [in] */ long Pool,
  109. /* [retval][out] */ IUnknown **ppTexture);
  110. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateTextureFromResource(
  111. /* [in] */ IUnknown *Device,
  112. #ifdef _WIN64
  113. /* [in] */ HANDLE hModule,
  114. #else
  115. /* [in] */ long hModule,
  116. #endif
  117. /* [in] */ BSTR SrcResource,
  118. /* [retval][out] */ IUnknown **ppTexture);
  119. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateTextureFromFile(
  120. /* [in] */ IUnknown *Device,
  121. /* [in] */ BSTR SrcFile,
  122. /* [retval][out] */ IUnknown **ppTexture);
  123. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateTextureFromFileEx(
  124. /* [in] */ IUnknown *Device,
  125. /* [in] */ BSTR SrcFile,
  126. /* [in] */ long Width,
  127. /* [in] */ long Height,
  128. /* [in] */ long MipLevels,
  129. /* [in] */ long Usage,
  130. /* [in] */ long PixelFormat,
  131. /* [in] */ long Pool,
  132. /* [in] */ long Filter,
  133. /* [in] */ long MipFilter,
  134. /* [in] */ long ColorKey,
  135. /* [in] */ void *SrcInfo,
  136. /* [in] */ void *Palette,
  137. /* [retval][out] */ IUnknown **ppTexture);
  138. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateTextureFromFileInMemory(
  139. /* [in] */ IUnknown *Device,
  140. /* [in] */ void *SrcData,
  141. /* [in] */ long LengthInBytes,
  142. /* [retval][out] */ IUnknown **ppTexture);
  143. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateTextureFromFileInMemoryEx(
  144. /* [in] */ IUnknown *Device,
  145. /* [in] */ void *SrcData,
  146. /* [in] */ long LengthInBytes,
  147. /* [in] */ long Width,
  148. /* [in] */ long Height,
  149. /* [in] */ long MipLevels,
  150. /* [in] */ long Usage,
  151. /* [in] */ long PixelFormat,
  152. /* [in] */ long Pool,
  153. /* [in] */ long Filter,
  154. /* [in] */ long MipFilter,
  155. /* [in] */ long ColorKey,
  156. /* [in] */ void *SrcInfo,
  157. /* [in] */ void *Palette,
  158. /* [retval][out] */ IUnknown **ppTexture);
  159. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE FilterTexture(
  160. /* [in] */ IUnknown *Texture,
  161. /* [in] */ void *Palette,
  162. /* [in] */ long SrcLevel,
  163. /* [in] */ long Filter);
  164. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CheckCubeTextureRequirements(
  165. /* [in] */ IUnknown *Device,
  166. /* [out][in] */ long *Size,
  167. /* [out][in] */ long *NumMipLevels,
  168. /* [in] */ long Usage,
  169. /* [out][in] */ long *PixelFormat,
  170. /* [in] */ long Pool);
  171. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateCubeTexture(
  172. /* [in] */ IUnknown *pDevice,
  173. /* [in] */ long Size,
  174. /* [in] */ long MipLevels,
  175. /* [in] */ long Usage,
  176. /* [in] */ long PixelFormat,
  177. /* [in] */ long Pool,
  178. /* [retval][out] */ IUnknown **ppCubeTexture);
  179. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateCubeTextureFromFile(
  180. /* [in] */ IUnknown *Device,
  181. /* [in] */ BSTR SrcFile,
  182. /* [retval][out] */ IUnknown **ppCubeTexture);
  183. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateCubeTextureFromFileEx(
  184. /* [in] */ IUnknown *Device,
  185. /* [in] */ BSTR SrcFile,
  186. /* [in] */ long TextureSize,
  187. /* [in] */ long MipLevels,
  188. /* [in] */ long Usage,
  189. /* [in] */ long PixelFormat,
  190. /* [in] */ long Pool,
  191. /* [in] */ long Filter,
  192. /* [in] */ long MipFilter,
  193. /* [in] */ long ColorKey,
  194. /* [in] */ void *SrcInfo,
  195. /* [in] */ void *Palette,
  196. /* [retval][out] */ IUnknown **ppTexture);
  197. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateCubeTextureFromFileInMemory(
  198. /* [in] */ IUnknown *Device,
  199. /* [in] */ void *SrcData,
  200. /* [in] */ long LengthInBytes,
  201. /* [retval][out] */ IUnknown **ppTexture);
  202. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateCubeTextureFromFileInMemoryEx(
  203. /* [in] */ IUnknown *Device,
  204. /* [in] */ void *SrcData,
  205. /* [in] */ long LengthInBytes,
  206. /* [in] */ long TextureSize,
  207. /* [in] */ long MipLevels,
  208. /* [in] */ long Usage,
  209. /* [in] */ long PixelFormat,
  210. /* [in] */ long Pool,
  211. /* [in] */ long Filter,
  212. /* [in] */ long MipFilter,
  213. /* [in] */ long ColorKey,
  214. /* [in] */ void *SrcInfo,
  215. /* [in] */ void *Palette,
  216. /* [retval][out] */ IUnknown **ppTexture);
  217. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE FilterCubeTexture(
  218. /* [in] */ IUnknown *CubeTexture,
  219. /* [in] */ void *Palette,
  220. /* [in] */ long SrcLevel,
  221. /* [in] */ long Filter);
  222. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CheckVolumeTextureRequirements(
  223. /* [in] */ IUnknown *Device,
  224. /* [out] */ long *Width,
  225. /* [out] */ long *Height,
  226. /* [out] */ long *Depth,
  227. /* [out] */ long *NumMipLevels,
  228. /* [in] */ long Usage,
  229. /* [out][in] */ long *PixelFormat,
  230. /* [in] */ long Pool);
  231. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateTextureFromResourceEx(
  232. /* [in] */ IUnknown *Device,
  233. #ifdef _WIN64
  234. /* [in] */ HANDLE hSrcModule,
  235. #else
  236. /* [in] */ long hSrcModule,
  237. #endif
  238. /* [in] */ BSTR SrcResource,
  239. /* [in] */ long Width,
  240. /* [in] */ long Height,
  241. /* [in] */ long MipLevels,
  242. /* [in] */ long Usage,
  243. /* [in] */ long PixelFormat,
  244. /* [in] */ long Pool,
  245. /* [in] */ long Filter,
  246. /* [in] */ long MipFilter,
  247. /* [in] */ long ColorKey,
  248. /* [in] */ void *SrcInfo,
  249. /* [in] */ void *Palette,
  250. /* [retval][out] */ IUnknown **retTexture);
  251. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateVolumeTexture(
  252. /* [in] */ IUnknown *Device,
  253. /* [in] */ long Width,
  254. /* [in] */ long Height,
  255. /* [in] */ long Depth,
  256. /* [in] */ long MipLevels,
  257. /* [in] */ long Usage,
  258. /* [in] */ long PixelFormat,
  259. /* [in] */ long Pool,
  260. /* [retval][out] */ IUnknown **ppVolumeTexture);
  261. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE FilterVolumeTexture(
  262. /* [in] */ IUnknown *VolumeTexture,
  263. /* [in] */ void *Palette,
  264. /* [in] */ long SrcLevel,
  265. /* [in] */ long Filter);
  266. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE LoadSurfaceFromResource(
  267. /* [in] */ IUnknown *DestSurface,
  268. /* [in] */ void *DestPalette,
  269. /* [in] */ void *DestRect,
  270. #ifdef _WIN64
  271. /* [in] */ HANDLE hSrcModule,
  272. #else
  273. /* [in] */ long hSrcModule,
  274. #endif
  275. /* [in] */ BSTR SrcResource,
  276. /* [in] */ void *SrcRect,
  277. /* [in] */ long Filter,
  278. /* [in] */ long ColorKey,
  279. /* [in] */ void *SrcInfo);
  280. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE LoadVolumeFromVolume(
  281. /* [in] */ IUnknown *DestVolume,
  282. /* [in] */ void *DestPalette,
  283. /* [in] */ void *DestBox,
  284. /* [in] */ IUnknown *SrcVolume,
  285. /* [in] */ void *SrcPalette,
  286. /* [in] */ void *SrcBox,
  287. /* [in] */ long Filter,
  288. /* [in] */ long ColorKey);
  289. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE LoadVolumeFromMemory(
  290. /* [in] */ IUnknown *DestVolume,
  291. /* [in] */ void *DestPalette,
  292. /* [in] */ void *DestRect,
  293. /* [in] */ void *SrcMemory,
  294. /* [in] */ long SrcFormat,
  295. /* [in] */ long SrcRowPitch,
  296. /* [in] */ long SrcSlicePitch,
  297. /* [in] */ void *SrcPalette,
  298. /* [in] */ void *SrcBox,
  299. /* [in] */ long Filter,
  300. /* [in] */ long ColorKey);
  301. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateMesh(
  302. /* [in] */ long numFaces,
  303. /* [in] */ long numVertices,
  304. /* [in] */ long options,
  305. /* [in] */ void *declaration,
  306. /* [in] */ IUnknown *pD3D,
  307. /* [retval][out] */ D3DXMesh **ppMesh);
  308. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateMeshFVF(
  309. /* [in] */ long numFaces,
  310. /* [in] */ long numVertices,
  311. /* [in] */ long options,
  312. /* [in] */ long fvf,
  313. /* [in] */ IUnknown *pD3D,
  314. /* [retval][out] */ D3DXMesh **ppMesh);
  315. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateSPMesh(
  316. /* [in] */ D3DXMesh *pMesh,
  317. /* [in] */ void *adjacency,
  318. /* [in] */ void *VertexAttributeWeights,
  319. /* [in] */ void *VertexWeights,
  320. /* [retval][out] */ D3DXSPMesh **ppSMesh);
  321. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE GeneratePMesh(
  322. /* [in] */ D3DXMesh *Mesh,
  323. /* [in] */ void *Adjacency,
  324. /* [in] */ void *VertexAttributeWeights,
  325. /* [in] */ void *VertexWeights,
  326. /* [in] */ long minValue,
  327. /* [in] */ long options,
  328. /* [retval][out] */ D3DXPMesh **ppPMesh);
  329. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE SimplifyMesh(
  330. /* [in] */ D3DXMesh *Mesh,
  331. /* [in] */ void *Adjacency,
  332. /* [in] */ void *VertexAttributeWeights,
  333. /* [in] */ void *VertexWeights,
  334. /* [in] */ long minValue,
  335. /* [in] */ long options,
  336. /* [retval][out] */ D3DXMesh **ppMesh);
  337. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE ComputeBoundingSphere(
  338. /* [in] */ void *PointsFVF,
  339. /* [in] */ long numVertices,
  340. /* [in] */ long FVF,
  341. /* [in] */ D3DVECTOR_CDESC *Centers,
  342. /* [out][in] */ float *RadiusArray);
  343. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE ComputeBoundingBox(
  344. /* [in] */ void *PointsFVF,
  345. /* [in] */ long numVertices,
  346. /* [in] */ long FVF,
  347. /* [out][in] */ D3DVECTOR_CDESC *MinVert,
  348. /* [out][in] */ D3DVECTOR_CDESC *MaxVert);
  349. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE ComputeNormals(
  350. /* [in] */ D3DXBaseMesh *pMesh);
  351. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE DeclaratorFromFVF(
  352. /* [in] */ long FVF,
  353. /* [out] */ D3DXDECLARATOR_CDESC *Declarator);
  354. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE FVFFromDeclarator(
  355. /* [in] */ D3DXDECLARATOR_CDESC *Declarator,
  356. /* [retval][out] */ long *fvf);
  357. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateBuffer(
  358. /* [in] */ long numBytes,
  359. /* [retval][out] */ D3DXBuffer **ppBuffer);
  360. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE LoadMeshFromX(
  361. /* [in] */ BSTR Filename,
  362. /* [in] */ long options,
  363. /* [in] */ IUnknown *D3DDevice,
  364. /* [out][in] */ D3DXBuffer **retAdjacency,
  365. /* [out][in] */ D3DXBuffer **retMaterials,
  366. /* [out][in] */ long *retMaterialCount,
  367. /* [retval][out] */ D3DXMesh **retMesh);
  368. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE SaveMeshToX(
  369. /* [in] */ BSTR Filename,
  370. /* [in] */ D3DXMesh *Mesh,
  371. /* [in] */ void *AdjacencyArray,
  372. /* [in] */ D3DXMATERIAL_CDESC *MaterialArray,
  373. /* [in] */ long MaterialCount,
  374. /* [in] */ long xFormat);
  375. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE LoadMeshFromXof(
  376. /* [in] */ IUnknown *xofobjMesh,
  377. /* [in] */ long options,
  378. /* [in] */ IUnknown *D3DDevice,
  379. /* [out][in] */ D3DXBuffer **retBufAdjacency,
  380. /* [out][in] */ D3DXBuffer **retMaterials,
  381. /* [out][in] */ long *retMaterialCount,
  382. /* [retval][out] */ D3DXMesh **retMesh);
  383. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE TessellateNPatches(
  384. /* [in] */ D3DXMesh *MeshIn,
  385. /* [in] */ void *AdjacencyIn,
  386. /* [in] */ float NumSegs,
  387. /* [in] */ VARIANT_BOOL QuadraticInterpNormals,
  388. /* [in,out, optional] */ D3DXBuffer **AdjacencyOut,
  389. /* [retval][out] */ D3DXMesh **MeshOut);
  390. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE BufferGetMaterial(
  391. /* [in] */ D3DXBuffer *MaterialBuffer,
  392. /* [in] */ long index,
  393. /* [out] */ D3DMATERIAL8_CDESC *mat);
  394. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE BufferGetTextureName(
  395. /* [in] */ D3DXBuffer *MaterialBuffer,
  396. /* [in] */ long index,
  397. /* [retval][out] */ BSTR *retName);
  398. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE BufferGetData(
  399. /* [in] */ D3DXBuffer *Buffer,
  400. /* [in] */ long index,
  401. /* [in] */ long typesize,
  402. /* [in] */ long typecount,
  403. /* [out][in] */ void *data);
  404. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE BufferSetData(
  405. /* [in] */ D3DXBuffer *Buffer,
  406. /* [in] */ long index,
  407. /* [in] */ long typesize,
  408. /* [in] */ long typecount,
  409. /* [out][in] */ void *data);
  410. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE Intersect(
  411. /* [in] */ D3DXMesh *MeshIn,
  412. /* [in] */ D3DVECTOR_CDESC *RayPos,
  413. /* [in] */ D3DVECTOR_CDESC *RayDir,
  414. /* [out] */ LONG *retHit,
  415. /* [out] */ LONG *retFaceIndex,
  416. /* [out] */ FLOAT *U,
  417. /* [out] */ FLOAT *V,
  418. /* [out] */ FLOAT *retDist,
  419. /* [out] */ LONG *countHits,
  420. /* [retval][out] */ D3DXBuffer **AllHits);
  421. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE SphereBoundProbe(
  422. /* [in] */ D3DVECTOR_CDESC *Center,
  423. /* [in] */ float Radius,
  424. /* [in] */ D3DVECTOR_CDESC *RayPosition,
  425. /* [in] */ D3DVECTOR_CDESC *Raydirection,
  426. /* [retval][out] */ VARIANT_BOOL *retHit);
  427. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE ComputeBoundingSphereFromMesh(
  428. /* [in] */ D3DXMesh *MeshIn,
  429. /* [out][in] */ D3DVECTOR_CDESC *Centers,
  430. /* [out][in] */ float *RadiusArray);
  431. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE ComputeBoundingBoxFromMesh(
  432. /* [in] */ D3DXMesh *MeshIn,
  433. /* [out][in] */ D3DVECTOR_CDESC *MinArray,
  434. /* [out][in] */ D3DVECTOR_CDESC *MaxArray);
  435. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateSkinMesh(
  436. /* [in] */ long numFaces,
  437. /* [in] */ long numVertices,
  438. /* [in] */ long numBones,
  439. /* [in] */ long options,
  440. /* [in] */ void *Declaration,
  441. /* [in] */ IUnknown *D3DDevice,
  442. /* [retval][out] */ D3DXSkinMesh **SkinMesh);
  443. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateSkinMeshFVF(
  444. /* [in] */ long numFaces,
  445. /* [in] */ long numVertices,
  446. /* [in] */ long numBones,
  447. /* [in] */ long options,
  448. /* [in] */ long fvf,
  449. /* [in] */ IUnknown *D3DDevice,
  450. /* [retval][out] */ D3DXSkinMesh **ppSkinMesh);
  451. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateSkinMeshFromMesh(
  452. /* [in] */ D3DXMesh *Mesh,
  453. /* [in] */ long numBones,
  454. /* [retval][out] */ D3DXSkinMesh **ppSkinMesh);
  455. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE LoadSkinMeshFromXof(
  456. /* [in] */ IUnknown *xofobjMesh,
  457. /* [in] */ long options,
  458. /* [in] */ IUnknown *D3DDevice,
  459. /* [out][in] */ D3DXBuffer **AdjacencyOut,
  460. /* [out][in] */ D3DXBuffer **MaterialsOut,
  461. /* [out][in] */ long *NumMatOut,
  462. /* [out][in] */ D3DXBuffer **BoneNamesOut,
  463. /* [out][in] */ D3DXBuffer **BoneTransformsOut,
  464. /* [retval][out] */ D3DXSkinMesh **ppMesh);
  465. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreatePolygon(
  466. /* [in] */ IUnknown *D3DDevice,
  467. /* [in] */ float Length,
  468. /* [in] */ long Sides,
  469. /* [out][in] */ D3DXBuffer **RetAdjacency,
  470. /* [retval][out] */ D3DXMesh **RetMesh);
  471. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateBox(
  472. /* [in] */ IUnknown *D3DDevice,
  473. /* [in] */ float Width,
  474. /* [in] */ float Height,
  475. /* [in] */ float Depth,
  476. /* [out][in] */ D3DXBuffer **RetAdjacency,
  477. /* [retval][out] */ D3DXMesh **RetMesh);
  478. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateCylinder(
  479. /* [in] */ IUnknown *D3DDevice,
  480. /* [in] */ float Radius1,
  481. /* [in] */ float Radius2,
  482. /* [in] */ float Length,
  483. /* [in] */ long Slices,
  484. /* [in] */ long Stacks,
  485. /* [out][in] */ D3DXBuffer **RetAdjacency,
  486. /* [retval][out] */ D3DXMesh **RetMesh);
  487. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateSphere(
  488. /* [in] */ IUnknown *D3DDevice,
  489. /* [in] */ float Radius,
  490. /* [in] */ long Slices,
  491. /* [in] */ long Stacks,
  492. /* [out][in] */ D3DXBuffer **RetAdjacency,
  493. /* [retval][out] */ D3DXMesh **RetMesh);
  494. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateTorus(
  495. /* [in] */ IUnknown *D3DDevice,
  496. /* [in] */ float InnerRadius,
  497. /* [in] */ float OuterRadius,
  498. /* [in] */ long Sides,
  499. /* [in] */ long Rings,
  500. /* [out][in] */ D3DXBuffer **RetAdjacency,
  501. /* [retval][out] */ D3DXMesh **RetMesh);
  502. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateTeapot(
  503. /* [in] */ IUnknown *D3DDevice,
  504. /* [out][in] */ D3DXBuffer **RetAdjacency,
  505. /* [retval][out] */ D3DXMesh **RetMesh);
  506. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateText(
  507. /* [in] */ IUnknown *D3DDevice,
  508. /* [in] */ HDC hDC,
  509. /* [in] */ BSTR Text,
  510. /* [in] */ float Deviation,
  511. /* [in] */ float Extrusion,
  512. /* [out][in] */ D3DXMesh **RetMesh,
  513. /* [in,out] */ D3DXBuffer **AdjacencyOut,
  514. /* [out][in] */ void *GlyphMetrics);
  515. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE BufferGetBoneName(
  516. /* [in] */ D3DXBuffer *BoneNameBuffer,
  517. /* [in] */ long index,
  518. /* [retval][out] */ BSTR *retName);
  519. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateSprite(
  520. /* [in] */ IUnknown *D3DDevice,
  521. /* [retval][out] */ D3DXSprite **retSprite);
  522. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CreateRenderToSurface(
  523. /* [in] */ IUnknown *D3DDevice,
  524. /* [in] */ long Width,
  525. /* [in] */ long Height,
  526. /* [in] */ long Format,
  527. /* [in] */ long DepthStencil,
  528. /* [in] */ long DepthStencilFormat,
  529. /* [retval][out] */ D3DXRenderToSurface **RetRenderToSurface);
  530. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE CleanMesh(
  531. /* [in] */ D3DXMesh *MeshIn,
  532. /* [in] */ void *Adjacency,
  533. /* [in][out][optional] */ BSTR *ErrLog,
  534. /* [in,out] */ D3DXBuffer *AdjacencyOut,
  535. /* [retval][out] */ D3DXMesh **MeshOut);
  536. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE ValidMesh(
  537. /* [in] */ D3DXMesh *MeshIn,
  538. /* [in] */ void *Adjacency,
  539. /* [in][out][optional] */ BSTR *ErrLog,
  540. /* [retval][out] */ VARIANT_BOOL *ret);
  541. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE BoxBoundProbe(
  542. /* [in] */ D3DVECTOR_CDESC *MinVert,
  543. /* [in] */ D3DVECTOR_CDESC *MaxVert,
  544. /* [in] */ D3DVECTOR_CDESC *RayPosition,
  545. /* [in] */ D3DVECTOR_CDESC *RayDirection,
  546. /* [retval][out] */ VARIANT_BOOL *ret);
  547. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE SavePMeshToFile(
  548. /* [in] */ BSTR Filename,
  549. /* [in] */ D3DXPMesh *Mesh,
  550. /* [in] */ D3DXMATERIAL_CDESC *MaterialArray,
  551. /* [in] */ long MaterialCount);
  552. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE LoadPMeshFromFile(
  553. /* [in] */ BSTR Filename,
  554. /* [in] */ long options,
  555. /* [in] */ IUnknown *D3DDevice,
  556. /* [out] */ D3DXBuffer **RetMaterials,
  557. /* [out] */ long *RetNumMaterials,
  558. /* [retval][out] */ D3DXPMesh **RetPMesh);
  559. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE BufferGetBoneCombo(
  560. /* [in] */ D3DXBuffer *BoneComboBuffer,
  561. /* [in] */ long index,
  562. /* [out][in] */ D3DXBONECOMBINATION_CDESC *boneCombo);
  563. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE BufferGetBoneComboBoneIds(
  564. /* [in] */ D3DXBuffer *BoneComboBuffer,
  565. /* [in] */ long index,
  566. /* [in] */ long PaletteSize,
  567. /* [in] */ void *BoneIds);
  568. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE SaveSurfaceToFile(
  569. /* [in] */ BSTR DestFile,
  570. /* [in] */ LONG DestFormat,
  571. /* [in] */ IUnknown* SrcSurface,
  572. /* [in] */ PALETTEENTRY* SrcPalette,
  573. /* [in] */ RECT* SrcRect);
  574. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE SaveVolumeToFile(
  575. /* [in] */ BSTR DestFile,
  576. /* [in] */ LONG DestFormat,
  577. /* [in] */ IUnknown* SrcVolume,
  578. /* [in] */ PALETTEENTRY* SrcPalette,
  579. /* [in] */ void* SrcBox);
  580. /* [helpcontext] */ HRESULT STDMETHODCALLTYPE SaveTextureToFile(
  581. /* [in] */ BSTR DestFile,
  582. /* [in] */ LONG DestFormat,
  583. /* [in] */ IUnknown* SrcTexture,
  584. /* [in] */ PALETTEENTRY* SrcPalette);
  585. };