Microsoft DirectX 8.1 (Visual Basic) |
Renders the specified geometric primitive, based on indexing into an array of vertices.
object.DrawIndexedPrimitive( _ PrimitiveType As CONST_D3DPRIMITIVETYPE, _ MinIndex As Long, _ NumIndices As Long, _ StartIndex As Long, _ PrimitiveCount 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.
This method draws indexed primitives from the current set of data input streams.
MinIndex and all the indices in the index stream are relative to the BaseVertexIndex, set during the Direct3DDevice8.SetIndices call.
The MinIndex and NumIndices parameters specify the range of vertex indices used for each DrawIndexedPrimitive call. These are used to optimize vertex processing of indexed primitives by processing a sequential range of vertices prior to indexing into these vertices. It is invalid for any indices used during this call to reference any vertices outside of this range.
DrawIndexedPrimitive fails if no index array is set.
The D3DPT_POINTLIST member of the CONST_D3DPRIMITIVETYPE enumeration is not supported and should not be specified for PrimitiveType.
Direct3DDevice8.DrawPrimitive, Direct3DDevice8.SetStreamSource, Rendering Primitives