File Annotation

Not logged in
9b639cf2d6 2015-05-05        kinaba: /***********************************************************************\
9b639cf2d6 2015-05-05        kinaba: *                              d3dx10mesh.d                             *
9b639cf2d6 2015-05-05        kinaba: *                                                                       *
9b639cf2d6 2015-05-05        kinaba: *                       Windows API header module                       *
9b639cf2d6 2015-05-05        kinaba: *                                                                       *
9b639cf2d6 2015-05-05        kinaba: *                       Placed into public domain                       *
9b639cf2d6 2015-05-05        kinaba: \***********************************************************************/
9b639cf2d6 2015-05-05        kinaba: module win32.directx.d3dx10mesh;
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: private import win32.windows;
9b639cf2d6 2015-05-05        kinaba: private import win32.directx.d3d10;
9b639cf2d6 2015-05-05        kinaba: private import win32.directx.d3dx10;
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: extern(C) const GUID IID_ID3DX10BaseMesh = {0x7ed943dd, 0x52e8, 0x40b5, [0xa8, 0xd8, 0x76, 0x68, 0x5c, 0x40, 0x63, 0x30]};
9b639cf2d6 2015-05-05        kinaba: extern(C) const GUID IID_ID3DX10MeshBuffer = {0x4b0d117, 0x1041, 0x46b1, [0xaa, 0x8a, 0x39, 0x52, 0x84, 0x8b, 0xa2, 0x2e]};
9b639cf2d6 2015-05-05        kinaba: extern(C) const GUID IID_ID3DX10Mesh = {0x4020e5c2, 0x1403, 0x4929, [0x88, 0x3f, 0xe2, 0xe8, 0x49, 0xfa, 0xc1, 0x95]};
9b639cf2d6 2015-05-05        kinaba: extern(C) const GUID IID_ID3DX10PMesh = {0x8875769a, 0xd579, 0x4088, [0xaa, 0xeb, 0x53, 0x4d, 0x1a, 0xd8, 0x4e, 0x96]};
9b639cf2d6 2015-05-05        kinaba: extern(C) const GUID IID_ID3DX10SPMesh = {0x667ea4c7, 0xf1cd, 0x4386, [0xb5, 0x23, 0x7c, 0x2, 0x90, 0xb8, 0x3c, 0xc5]};
9b639cf2d6 2015-05-05        kinaba: extern(C) const GUID IID_ID3DX10PatchMesh = {0x3ce6cc22, 0xdbf2, 0x44f4, [0x89, 0x4d, 0xf9, 0xc3, 0x4a, 0x33, 0x71, 0x39]};
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: enum D3DX10_MESH {
9b639cf2d6 2015-05-05        kinaba:     D3DX10_MESH_32_BIT			= 0x001,
9b639cf2d6 2015-05-05        kinaba:     D3DX10_MESH_GS_ADJACENCY	= 0x004
9b639cf2d6 2015-05-05        kinaba: }
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: struct D3DX10_ATTRIBUTE_RANGE {
9b639cf2d6 2015-05-05        kinaba:     UINT	AttribId;
9b639cf2d6 2015-05-05        kinaba:     UINT	FaceStart;
9b639cf2d6 2015-05-05        kinaba:     UINT	FaceCount;
9b639cf2d6 2015-05-05        kinaba:     UINT	VertexStart;
9b639cf2d6 2015-05-05        kinaba:     UINT	VertexCount;
9b639cf2d6 2015-05-05        kinaba: }
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: enum D3DX10_MESH_DISCARD_FLAGS {
9b639cf2d6 2015-05-05        kinaba:     D3DX10_MESH_DISCARD_ATTRIBUTE_BUFFER = 0x01,
9b639cf2d6 2015-05-05        kinaba:     D3DX10_MESH_DISCARD_ATTRIBUTE_TABLE = 0x02,
9b639cf2d6 2015-05-05        kinaba:     D3DX10_MESH_DISCARD_POINTREPS = 0x04,
9b639cf2d6 2015-05-05        kinaba:     D3DX10_MESH_DISCARD_ADJACENCY = 0x08,
9b639cf2d6 2015-05-05        kinaba:     D3DX10_MESH_DISCARD_DEVICE_BUFFERS = 0x10
9b639cf2d6 2015-05-05        kinaba: }
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: struct D3DX10_WELD_EPSILONS {
9b639cf2d6 2015-05-05        kinaba:     FLOAT Position;
9b639cf2d6 2015-05-05        kinaba:     FLOAT BlendWeights;
9b639cf2d6 2015-05-05        kinaba:     FLOAT Normal;
9b639cf2d6 2015-05-05        kinaba:     FLOAT PSize;
9b639cf2d6 2015-05-05        kinaba:     FLOAT Specular;
9b639cf2d6 2015-05-05        kinaba:     FLOAT Diffuse;
9b639cf2d6 2015-05-05        kinaba:     FLOAT[8] Texcoord;
9b639cf2d6 2015-05-05        kinaba:     FLOAT Tangent;
9b639cf2d6 2015-05-05        kinaba:     FLOAT Binormal;
9b639cf2d6 2015-05-05        kinaba:     FLOAT TessFactor;
9b639cf2d6 2015-05-05        kinaba: }
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: struct D3DX10_INTERSECT_INFO {
9b639cf2d6 2015-05-05        kinaba:     UINT	FaceIndex;
9b639cf2d6 2015-05-05        kinaba:     FLOAT	U;
9b639cf2d6 2015-05-05        kinaba:     FLOAT	V;
9b639cf2d6 2015-05-05        kinaba:     FLOAT	Dist;
9b639cf2d6 2015-05-05        kinaba: }
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: interface ID3DX10MeshBuffer : IUnknown {
9b639cf2d6 2015-05-05        kinaba: 	extern(Windows) :
9b639cf2d6 2015-05-05        kinaba:     HRESULT Map(void** ppData, SIZE_T* pSize);
9b639cf2d6 2015-05-05        kinaba:     HRESULT Unmap();
9b639cf2d6 2015-05-05        kinaba:     SIZE_T GetSize();
9b639cf2d6 2015-05-05        kinaba: }
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: interface ID3DX10Mesh : IUnknown {
9b639cf2d6 2015-05-05        kinaba: 	extern(Windows) :
9b639cf2d6 2015-05-05        kinaba:     UINT GetFaceCount();
9b639cf2d6 2015-05-05        kinaba:     UINT GetVertexCount();
9b639cf2d6 2015-05-05        kinaba:     UINT GetVertexBufferCount();
9b639cf2d6 2015-05-05        kinaba:     UINT GetFlags();
9b639cf2d6 2015-05-05        kinaba:     HRESULT GetVertexDescription(D3D10_INPUT_ELEMENT_DESC** ppDesc, UINT* pDeclCount);
9b639cf2d6 2015-05-05        kinaba:     HRESULT SetVertexData(UINT iBuffer, void* pData);
9b639cf2d6 2015-05-05        kinaba:     HRESULT GetVertexBuffer(UINT iBuffer, ID3DX10MeshBuffer** ppVertexBuffer);
9b639cf2d6 2015-05-05        kinaba:     HRESULT SetIndexData(void* pData, UINT cIndices);
9b639cf2d6 2015-05-05        kinaba:     HRESULT GetIndexBuffer(ID3DX10MeshBuffer** ppIndexBuffer);
9b639cf2d6 2015-05-05        kinaba:     HRESULT SetAttributeData(UINT* pData);
9b639cf2d6 2015-05-05        kinaba:     HRESULT GetAttributeBuffer(ID3DX10MeshBuffer** ppAttributeBuffer);
9b639cf2d6 2015-05-05        kinaba:     HRESULT SetAttributeTable(D3DX10_ATTRIBUTE_RANGE* pAttribTable, UINT  cAttribTableSize);
9b639cf2d6 2015-05-05        kinaba:     HRESULT GetAttributeTable(D3DX10_ATTRIBUTE_RANGE* pAttribTable, UINT* pAttribTableSize);
9b639cf2d6 2015-05-05        kinaba:     HRESULT GenerateAdjacencyAndPointReps(FLOAT Epsilon);
9b639cf2d6 2015-05-05        kinaba:     HRESULT GenerateGSAdjacency();
9b639cf2d6 2015-05-05        kinaba:     HRESULT SetAdjacencyData(UINT* pAdjacency);
9b639cf2d6 2015-05-05        kinaba:     HRESULT GetAdjacencyBuffer(ID3DX10MeshBuffer** ppAdjacency);
9b639cf2d6 2015-05-05        kinaba:     HRESULT SetPointRepData(UINT* pPointReps);
9b639cf2d6 2015-05-05        kinaba:     HRESULT GetPointRepBuffer(ID3DX10MeshBuffer** ppPointReps);
9b639cf2d6 2015-05-05        kinaba:     HRESULT Discard(D3DX10_MESH_DISCARD_FLAGS dwDiscard);
9b639cf2d6 2015-05-05        kinaba:     HRESULT CloneMesh(UINT Flags, LPCSTR pPosSemantic, D3D10_INPUT_ELEMENT_DESC* pDesc, UINT  DeclCount, ID3DX10Mesh** ppCloneMesh);
9b639cf2d6 2015-05-05        kinaba:     HRESULT Optimize(UINT Flags, UINT * pFaceRemap, ID3D10Blob* ppVertexRemap);
9b639cf2d6 2015-05-05        kinaba:     HRESULT GenerateAttributeBufferFromTable();
9b639cf2d6 2015-05-05        kinaba: 	HRESULT Intersect(D3DXVECTOR3* pRayPos, D3DXVECTOR3* pRayDir, UINT* pHitCount, UINT* pFaceIndex, float* pU, float* pV, float* pDist, ID3D10Blob* ppAllHits);
9b639cf2d6 2015-05-05        kinaba: 	HRESULT IntersectSubset(UINT AttribId, D3DXVECTOR3* pRayPos, D3DXVECTOR3* pRayDir, UINT* pHitCount, UINT* pFaceIndex, float* pU, float* pV, float* pDist, ID3D10Blob* ppAllHits);
9b639cf2d6 2015-05-05        kinaba:     HRESULT CommitToDevice();
9b639cf2d6 2015-05-05        kinaba:     HRESULT DrawSubset(UINT AttribId);
9b639cf2d6 2015-05-05        kinaba:     HRESULT DrawSubsetInstanced(UINT AttribId, UINT InstanceCount, UINT StartInstanceLocation);
9b639cf2d6 2015-05-05        kinaba:     HRESULT GetDeviceVertexBuffer(UINT iBuffer, ID3D10Buffer** ppVertexBuffer);
9b639cf2d6 2015-05-05        kinaba:     HRESULT GetDeviceIndexBuffer(ID3D10Buffer** ppIndexBuffer);
9b639cf2d6 2015-05-05        kinaba: }
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: HRESULT D3DX10CreateMesh(ID3D10Device* pDevice, D3D10_INPUT_ELEMENT_DESC* pDeclaration, UINT  DeclCount, LPCSTR pPositionSemantic, UINT  VertexCount, UINT  FaceCount, UINT  Options, ID3DX10Mesh** ppMesh);
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: enum D3DX10_MESHOPT {
9b639cf2d6 2015-05-05        kinaba:     D3DX10_MESHOPT_COMPACT				= 0x01000000,
9b639cf2d6 2015-05-05        kinaba:     D3DX10_MESHOPT_ATTR_SORT			= 0x02000000,
9b639cf2d6 2015-05-05        kinaba:     D3DX10_MESHOPT_VERTEX_CACHE			= 0x04000000,
9b639cf2d6 2015-05-05        kinaba:     D3DX10_MESHOPT_STRIP_REORDER		= 0x08000000,
9b639cf2d6 2015-05-05        kinaba:     D3DX10_MESHOPT_IGNORE_VERTS			= 0x10000000,
9b639cf2d6 2015-05-05        kinaba:     D3DX10_MESHOPT_DO_NOT_SPLIT			= 0x20000000,
9b639cf2d6 2015-05-05        kinaba:     D3DX10_MESHOPT_DEVICE_INDEPENDENT	= 0x00400000
9b639cf2d6 2015-05-05        kinaba: }
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: extern(C) const GUID IID_ID3DX10SkinInfo = {0x420bd604, 0x1c76, 0x4a34, [0xa4, 0x66, 0xe4, 0x5d, 0x6, 0x58, 0xa3, 0x2c]};
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: const D3DX10_SKININFO_NO_SCALING = 0;
9b639cf2d6 2015-05-05        kinaba: const D3DX10_SKININFO_SCALE_TO_1 = 1;
9b639cf2d6 2015-05-05        kinaba: const D3DX10_SKININFO_SCALE_TO_TOTAL = 2;
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: struct D3DX10_SKINNING_CHANNEL {
9b639cf2d6 2015-05-05        kinaba:     UINT SrcOffset;
9b639cf2d6 2015-05-05        kinaba:     UINT DestOffset;
9b639cf2d6 2015-05-05        kinaba:     BOOL IsNormal;
9b639cf2d6 2015-05-05        kinaba: }
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: interface ID3DX10SkinInfo : IUnknown {
9b639cf2d6 2015-05-05        kinaba: 	extern(Windows) :
9b639cf2d6 2015-05-05        kinaba: 	HRESULT QueryInterface(REFIID iid, LPVOID* ppv);
9b639cf2d6 2015-05-05        kinaba: 	ULONG AddRef();
9b639cf2d6 2015-05-05        kinaba: 	ULONG Release();
9b639cf2d6 2015-05-05        kinaba: 	UINT GetNumVertices();
9b639cf2d6 2015-05-05        kinaba: 	UINT GetNumBones();
9b639cf2d6 2015-05-05        kinaba: 	UINT GetMaxBoneInfluences();
9b639cf2d6 2015-05-05        kinaba: 	HRESULT AddVertices(UINT Count);
9b639cf2d6 2015-05-05        kinaba: 	HRESULT RemapVertices(UINT NewVertexCount, UINT* pVertexRemap);
9b639cf2d6 2015-05-05        kinaba: 	HRESULT AddBones(UINT Count);
9b639cf2d6 2015-05-05        kinaba: 	HRESULT RemoveBone(UINT Index);
9b639cf2d6 2015-05-05        kinaba: 	HRESULT RemapBones(UINT NewBoneCount, UINT* pBoneRemap);
9b639cf2d6 2015-05-05        kinaba: 	HRESULT AddBoneInfluences(UINT BoneIndex, UINT InfluenceCount, UINT* pIndices, float* pWeights);
9b639cf2d6 2015-05-05        kinaba: 	HRESULT ClearBoneInfluences(UINT BoneIndex);
9b639cf2d6 2015-05-05        kinaba: 	UINT GetBoneInfluenceCount(UINT BoneIndex);
9b639cf2d6 2015-05-05        kinaba: 	HRESULT GetBoneInfluences(UINT BoneIndex, UINT Offset, UINT Count, UINT* pDestIndices, float* pDestWeights);
9b639cf2d6 2015-05-05        kinaba: 	HRESULT FindBoneInfluenceIndex(UINT BoneIndex, UINT VertexIndex, UINT* pInfluenceIndex);
9b639cf2d6 2015-05-05        kinaba: 	HRESULT SetBoneInfluence(UINT BoneIndex, UINT InfluenceIndex, float Weight);
9b639cf2d6 2015-05-05        kinaba: 	HRESULT GetBoneInfluence(UINT BoneIndex, UINT InfluenceIndex, float* pWeight);
9b639cf2d6 2015-05-05        kinaba: 	HRESULT Compact(UINT MaxPerVertexInfluences, UINT ScaleMode, float MinWeight);
9b639cf2d6 2015-05-05        kinaba: 	HRESULT DoSoftwareSkinning(UINT StartVertex, UINT VertexCount, void* pSrcVertices, UINT SrcStride, void* pDestVertices, UINT DestStride, D3DXMATRIX* pBoneMatrices, D3DXMATRIX* pInverseTransposeBoneMatrices, D3DX10_SKINNING_CHANNEL* pChannelDescs, UINT NumChannels);
9b639cf2d6 2015-05-05        kinaba: }
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: HRESULT D3DX10CreateSkinInfo(ID3DX10SkinInfo* ppSkinInfo);
9b639cf2d6 2015-05-05        kinaba: 
9b639cf2d6 2015-05-05        kinaba: struct D3DX10_ATTRIBUTE_WEIGHTS {
9b639cf2d6 2015-05-05        kinaba: 	FLOAT Position;
9b639cf2d6 2015-05-05        kinaba: 	FLOAT Boundary;
9b639cf2d6 2015-05-05        kinaba: 	FLOAT Normal;
9b639cf2d6 2015-05-05        kinaba: 	FLOAT Diffuse;
9b639cf2d6 2015-05-05        kinaba: 	FLOAT Specular;
9b639cf2d6 2015-05-05        kinaba: 	FLOAT[8] Texcoord;
9b639cf2d6 2015-05-05        kinaba: 	FLOAT Tangent;
9b639cf2d6 2015-05-05        kinaba: 	FLOAT Binormal;
9b639cf2d6 2015-05-05        kinaba: }
9b639cf2d6 2015-05-05        kinaba: