Interface IComputeBuffer<T>
- Namespace
- Orleans.GpuBridge.Runtime.BackendProviders.Interfaces
- Assembly
- Orleans.GpuBridge.Runtime.dll
Compute buffer interface for GPU memory management.
public interface IComputeBuffer<T> : IDisposable where T : unmanaged
Type Parameters
TThe unmanaged element type stored in the buffer.
- Inherited Members
Properties
Size
Gets the number of elements in the buffer.
int Size { get; }
Property Value
Usage
Gets the intended usage pattern for this buffer.
BufferUsage Usage { get; }
Property Value
Methods
CopyTo(IComputeBuffer<T>)
Copies the contents of this buffer to another compute buffer.
void CopyTo(IComputeBuffer<T> destination)
Parameters
destinationIComputeBuffer<T>The target buffer to copy data to.
Read(Span<T>)
Reads data from the compute buffer to the host.
void Read(Span<T> data)
Parameters
dataSpan<T>The destination span to receive the data.
Write(ReadOnlySpan<T>)
Writes data from the host to the compute buffer.
void Write(ReadOnlySpan<T> data)
Parameters
dataReadOnlySpan<T>The source data to write.