| Microsoft DirectX 8.1 (Visual Basic) |
Copies vertices from a vertex buffer attached to a mesh object into an vertex array.
D3DXMeshVertexBuffer8GetData( _
D3DXMeshobj As Unknown, _
Offset As Long, _
Size As Long, _
Flags As Long, _
Data As Any) As Long
If the function succeeds, the return value is D3D_OK.
If the function fails, the return value can be one of the following.
| D3DERR_INVALIDCALL |
| E_INVALIDARG |
Err.Number is not set for this function.
The following code fragment demonstrates a typical use for this function.
Dim VertArray(9) As D3DVERTEX
Dim Mesh As D3DXMesh
Dim hr As Long
'The following code assumes that Mesh has been properly initialized
hr = D3DXMeshVertexBuffer8GetData(Mesh, 0, (Len(VertArray(0)) * 10), _
0, VertArray(0))