ID3DXSPMesh::CloneMeshFVF

Bb174234.XDK_CHM_BANNER_left(en-us,VS.85).jpg Bb174234.XDK_CHM_BANNER_right(en-us,VS.85).jpg

NOTE: The ID3DXPMesh and ID3DXSPMesh interfaces are now obsolete and will be removed in a future release.

ID3DXSPMesh::CloneMeshFVF

Clones a mesh using a flexible vertex format (FVF) code.

  HRESULT 
  CloneMeshFVF(
  DWORD Options,
  DWORD FVF,
  LPDIRECT3DDEVICE9 pD3DDevice,
  DWORD * pAdjacencyOut,
  DWORD * pVertexRemapOut,
  LPD3DXMESH * ppCloneMesh
);

Parameters

  • Options
    [in] Combination of one or more flags from the D3DXMESH enumeration, specifying creation options for the mesh.
  • FVF
    [in] Combination of FVF codes, specifying the vertex format for the vertices in the output mesh. For the values of the codes, see D3DFVF.
  • pD3DDevice
    [in] Pointer to an IDirect3DDevice9 interface, representing the device object associated with the mesh.
  • pAdjacencyOut
    [out] Pointer to an array of three DWORDs per face, specifying the three neighbors for each face in the source mesh.
  • pVertexRemapOut
    [out] Pointer to an array containing the index for each vertex.
  • ppCloneMesh
    [out] Address of a pointer to an ID3DXPMesh interface, representing the cloned mesh.

Return Values

If the method succeeds, the return value is D3D_OK. If the method fails, the return value can be one of the following: D3DERR_INVALIDCALL, E_OUTOFMEMORY.

Remarks

CloneMeshFVF can be used to convert a mesh from one FVF to another.

Requirements

Header: Declared in D3DX9Mesh.h.

Library: Use D3dx9.lib.

See Also

ID3DXSPMesh::GetFVF, D3DXFVFFromDeclarator