Microsoft DirectX 8.1 (Visual Basic) |
Cleans a mesh, preparing it for simplification.
object.CleanMesh( _ MeshIn As D3DXMesh, _ Adjacency As Any) As D3DXMesh
D3DXMesh object, representing the returned cleaned mesh.
If the method fails, an error is raised and Err.Number can be set to one of the following values.
D3DERR_INVALIDCALL |
E_OUTOFMEMORY |
For information on trapping errors, see the Microsoft® Visual Basic® Error Handling topic.
This method cleans the mesh by adding another vertex where two fans of triangles share the same vertex.
The following code fragment shows how to use a D3DXBuffer object to pass adjacency information.
Dim d3dxbAdjacency As D3DXBuffer Dim mesh As D3DXMesh ' This code fragment assumes that d3dxbAdjacency and mesh have been properly ' initialized. Call D3DX8.CleanMesh(d3dxm, ByVal d3dxbAdjacency.GetBufferPointer)