Added Buffer2<T>.GetData() overload
このコミットが含まれているのは:
1 親
bde2f35fe6
コミット
79c4df4a09
1ファイル変更
+13
@@ -119,6 +119,19 @@ namespace ComputeSharp.Graphics.Buffers
|
||||
set => throw new InvalidOperationException("The indexer APIs can only be used from a compute shader");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Reads the contents of the current <see cref="Buffer2{T}"/> instance and returns an array
|
||||
/// </summary>
|
||||
/// <returns>A <typeparamref name="T"/> array with the contents of the current buffer</returns>
|
||||
[Pure]
|
||||
public T[] GetData()
|
||||
{
|
||||
T[] data = new T[Size];
|
||||
GetData(data);
|
||||
|
||||
return data;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Reads the contents of the current <see cref="Buffer2{T}"/> instance and writes them into a target <see cref="Span{T}"/>
|
||||
/// </summary>
|
||||
|
||||
新しいイシューから参照
ユーザーをブロックする