Hallo,
mal ne Frage zur Meshzerlegung,
was genau beudeten in folgender Funktion die Parameter die ich mit ??? gekennzeichnet hab?
Im Internet find ich absolut nix, im SDK steht auch nix weiter, aber die Funktion scheint recht hilfreich zu sein.
Und zweite Frage:
Wie greif ich auf die Teil-Meshes dann genau zu?
|
Quellcode
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
void D3DXSplitMesh
(
const LPD3DXMESH pMeshIn, // Zeiger zu Mesh welches zerlegt werden soll
const DWORD *pAdjacencyIn, // ???
const DWORD MaxSize, // Maximale Anzahl der Vertexe
const DWORD Options, // ???
DWORD *pMeshesOut, // Anzahl neuer Meshes
LPD3DXBUFFER *ppMeshArrayOut, // Zeiger zu neuen Mesh
LPD3DXBUFFER *ppAdjacencyArrayOut,
LPD3DXBUFFER *ppFaceRemapArrayOut,
LPD3DXBUFFER *ppVertRemapArrayOut
);
pMeshIn
[in] Pointer to an ID3DXMesh interface, representing the source mesh.
pAdjacencyIn
[in] Pointer to an array of three DWORDs per face that specify the three neighbors for each face in the mesh to be simplified.
MaxSize
[in] Maximum number of vertices in the resulting mesh.
Options
[in] Option flags for the new meshes.
pMeshesOut
[out, retval] Number of meshes returned.
ppMeshArrayOut
[out, retval] Buffer containing an array of ID3DXMesh interfaces for the new meshes. For a source mesh split into n meshes, ppMeshArrayOut is an array of n ID3DXMesh pointers.
ppAdjacencyArrayOut
[out, retval] Buffer containing an array of adjacency arrays (DWORDs) for the new meshes. See ID3DXBuffer. This parameter is optional.
ppFaceRemapArrayOut
[out, retval] Buffer containing an array of face remap arrays (DWORDs) for the new meshes. See ID3DXBuffer. This parameter is optional.
ppVertRemapArrayOut
[out, retval] Buffer containing an array of vertex remap arrays for the new meshes. See ID3DXBuffer. This parameter is optional.
|