Method UseList
UseList(List<T>, CommandBuffer)
Sets the internal CPU list to refer to the given one, then sends the list to the GPU buffer, allocating or resizing it if necessary.
Declaration
public void UseList(List<T> data, CommandBuffer cmd = null)
Parameters
Type | Name | Description |
---|---|---|
List<T> | data | The data to set. Cannot be null. |
CommandBuffer | cmd | An optional command buffer to add the command to. |
Remarks
UseList will share the same list between the caller and the ExchangeBuffer. The caller must not alter the contents of the list after the call to UseList. Previous contents of the underlying buffer and list are ignored. Use a command buffer to ensure proper synchronization. If not, call the function during Update or before.