Microsoft DirectX 8.1 (Visual Basic) |
object.SetIndices( _ IndexData As Direct3DIndexBuffer8, _ BaseVertexIndex As Long)
If the method fails, an error is raised and Err.Number can be set to D3DERR_INVALIDCALL.
For information on trapping errors, see the Microsoft® Visual Basic® Error Handling topic.
The SetIndices method sets the current index array to an index buffer. The single set of indices is used to index all streams.
The BaseVertexIndex parameter specifies the base value for indices. This base value is added to all indices prior to referencing into the vertex data streams, which results in setting a starting position in the vertex data streams. The base vertex index enables multiple indexed primitives to be packed into a single set of vertex data without requiring the indices to be recomputed based on where the corresponding primitive is placed in the vertex data.