From b237fb55c274899e3d0889b95038d3ba079617bc Mon Sep 17 00:00:00 2001 From: Stephen Gutekanst Date: Tue, 26 Jul 2022 20:28:17 -0700 Subject: [PATCH] gpu: implement CommandBuffer methods Signed-off-by: Stephen Gutekanst --- gpu/src/command_buffer.zig | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/gpu/src/command_buffer.zig b/gpu/src/command_buffer.zig index 09f7c42d..a401ef66 100644 --- a/gpu/src/command_buffer.zig +++ b/gpu/src/command_buffer.zig @@ -1,14 +1,18 @@ const ChainedStruct = @import("types.zig").ChainedStruct; +const impl = @import("interface.zig").impl; pub const CommandBuffer = *opaque { - // TODO - // pub inline fn commandBufferSetLabel(command_buffer: gpu.CommandBuffer, label: [*:0]const u8) void { + pub inline fn setLabel(command_buffer: CommandBuffer, label: [*:0]const u8) void { + impl.commandBufferSetLabel(command_buffer, label); + } - // TODO - // pub inline fn commandBufferReference(command_buffer: gpu.CommandBuffer) void { + pub inline fn reference(command_buffer: CommandBuffer) void { + impl.commandBufferReference(command_buffer); + } - // TODO - // pub inline fn commandBufferRelease(command_buffer: gpu.CommandBuffer) void { + pub inline fn release(command_buffer: CommandBuffer) void { + impl.commandBufferRelease(command_buffer); + } }; pub const CommandBufferDescriptor = extern struct {