Updates the MeshData's vertex data. This applies to both the CPU copy and the GPU (VertexxBuffer) copy, if
the latter exists. Error will occur trying to set data that is not valid (either did not exist with an
already constructed vertex buffer, or type mismatch)
Declaration Syntax
C# |
public void UpdateVertexData<T>( VertexSemantic semantic, int startVertex, DataBuffer<T> data, int startIndex, int elementCount, DataWriteOptions options ) where T : struct, new()
Generic Template Parameters
- T
- Type parameter specifying vertex element type
Parameters
- semantic (VertexSemantic)
- Vertex semantic.
- startVertex (Int32)
- The starting vertex in the vertex buffer at which to write.
- data (DataBuffer<(Of <(<'T>)>)>)
- The vertex data.
- startIndex (Int32)
- The starting index in the data to read from..
- elementCount (Int32)
- The number of elements to write.
- options (DataWriteOptions)
- The write options for dynamic vertex buffers.
Exceptions
Exception | Condition |
---|---|
ArgumentNullException | Thrown if the data is null |
ArgumentException | Thrown if the vertex element data to write does not match with an existing type in the buffer. due to type mismatch or data size |
ArgumentOutOfRangeException | Thrown if number of elements to write will be out of range. |
Assembly: Tesla (Module: Tesla) Version: 0.5.0.0 (0.5.0.0)