Microsoft DirectX 8.1 (Visual Basic) |
Binds a vertex buffer to a device data stream.
object.SetStreamSource( _ StreamNumber As Long, _ StreamData As Direct3DVertexBuffer8, _ Stride 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.
When a flexible vertex format (FVF) vertex shader is used, the stream vertex stride in SetStreamSource must match the vertex size, computed from the FVF. When a declaration is used, the stream vertex stride in SetStreamSource should be greater than or equal to the stream size, computed from the declaration.
The SetStreamSource method binds a vertex buffer to a device data stream. For details, see Setting the Stream Source.
Direct3DDevice8.DrawIndexedPrimitive, Direct3DDevice8.DrawIndexedPrimitiveUP, Direct3DDevice8.DrawPrimitive, Direct3DDevice8.DrawPrimitiveUP, Direct3DDevice8.GetStreamSource