?/TD>
Microsoft DirectX 9.0

ID3DXAllocateHierarchy::CreateMeshContainer Method


Requests allocation of a mesh container object.

Syntax

HRESULT CreateMeshContainer(      

    LPCSTR Name,     LPD3DXMESHDATA pMeshData,     LPD3DXMATERIAL pMaterials,     LPD3DXEFFECTINSTANCE pEffectInstances,     DWORD NumMaterials,     DWORD *pAdjacency,     LPD3DXSKININFO pSkinInfo,     LPD3DXMESHCONTAINER *ppNewMeshContainer );

Parameters

Name
[in] Name of the mesh.
pMeshData
[in] Pointer to the mesh data structure. See D3DXMESHDATA.
pMaterials
[in] Array of materials used in the mesh.
pEffectInstances
[in] Array of effect instances used in the mesh. See D3DXEFFECTINSTANCE.
NumMaterials
[in] Number of materials in the materials array.
pAdjacency
[in] Adjacency array for the mesh.
pSkinInfo
[in] Pointer to the skin mesh object if skin data is found. See ID3DXSkinInfo.
ppNewMeshContainer
[out, retval] Returns the created mesh container. See D3DXMESHCONTAINER.

Return Value

The return values of this method are implemented by an application programmer. In general, if no error occurs, program the method to return D3D_OK. Otherwise, program the method to return an appropriate error message from D3DERR or D3DXERR, as this will cause D3DXLoadMeshHierarchyFromX to fail also, and return the error.





© 2002 Microsoft Corporation. All rights reserved.