gpu: enable slice helpers to take arrays
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
parent
3104083143
commit
c09b587db9
2 changed files with 6 additions and 3 deletions
|
|
@ -86,8 +86,9 @@ pub const CommandEncoder = opaque {
|
|||
command_encoder: *CommandEncoder,
|
||||
buffer: *Buffer,
|
||||
buffer_offset_bytes: u64,
|
||||
data_slice: anytype,
|
||||
data_span: anytype,
|
||||
) void {
|
||||
const data_slice = std.mem.span(data_span);
|
||||
Impl.commandEncoderWriteBuffer(
|
||||
command_encoder,
|
||||
buffer,
|
||||
|
|
|
|||
|
|
@ -58,8 +58,9 @@ pub const Queue = opaque {
|
|||
queue: *Queue,
|
||||
buffer: *Buffer,
|
||||
buffer_offset_bytes: u64,
|
||||
data_slice: anytype,
|
||||
data_span: anytype,
|
||||
) void {
|
||||
const data_slice = std.mem.span(data_span);
|
||||
Impl.queueWriteBuffer(
|
||||
queue,
|
||||
buffer,
|
||||
|
|
@ -74,8 +75,9 @@ pub const Queue = opaque {
|
|||
destination: *const ImageCopyTexture,
|
||||
data_layout: *const Texture.DataLayout,
|
||||
write_size: *const Extent3D,
|
||||
data_slice: anytype,
|
||||
data_span: anytype,
|
||||
) void {
|
||||
const data_slice = std.mem.span(data_span);
|
||||
Impl.queueWriteTexture(
|
||||
queue,
|
||||
destination,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue