IDirect3DMobileDevice::SetStreamSource (Windows Embedded CE 6.0)
This method binds a vertex buffer to a device data stream.
HRESULT SetStreamSource( UINT StreamNumber, IDirect3DMobileVertexBuffer* pStreamData, UINT Stride );
[in] A UINT value identifying the data stream. This parameter is not used. The Direct3D Mobile middleware is hard-coded to use zero for this value.
[in] Pointer to an IDirect3DMobileVertexBuffer interface that represents the vertex buffer to bind to the specified data stream.
[in] A UINT value that indicates the stride of the vertex buffer. You can only set this value to zero, or the vertex size implied by the vertex buffer's flexible vertex format (FVF).
Unlike the Direct3D implementations found on Windows-based desktop where vertex buffers can be bound to specific device data streams, Direct3D Mobile only supports vertex buffers bound to stream zero.
This method increments the reference count of the stream being assigned. When the stream is no longer needed, set it to NULL. If you fail to do this, the surface is not released, which results in a memory leak.
When a flexible vertex format (FVF) vertex shader is used, the stream vertex stride in IDirect3DMobileDevice::SetStreamSource must match the vertex size, computed from the FVF. When a declaration is used, the stream vertex stride in IDirect3DMobileDevice::SetStreamSource should be greater than or equal to the stream size computed from the declaration.
The IDirect3DMobileDevice::SetStreamSource method binds a vertex buffer to a device data stream.