gpu: make CommandBuffer an enum with methods
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
parent
7563a18ca3
commit
9ff6409d73
3 changed files with 7 additions and 3 deletions
|
|
@ -1 +0,0 @@
|
|||
ptr: *anyopaque,
|
||||
5
gpu/src/command_buffer.zig
Normal file
5
gpu/src/command_buffer.zig
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
pub const CommandBuffer = enum(usize) {
|
||||
_,
|
||||
|
||||
pub const none: CommandBuffer = @intToEnum(CommandBuffer, 0);
|
||||
};
|
||||
|
|
@ -13,7 +13,7 @@ pub const Adapter = @import("adapter.zig").Adapter;
|
|||
pub const BindGroup = @import("bind_group.zig").BindGroup;
|
||||
pub const BindGroupLayout = @import("bind_group_layout.zig").BindGroupLayout;
|
||||
pub const Buffer = @import("buffer.zig").Buffer;
|
||||
pub const CommandBuffer = @import("CommandBuffer.zig");
|
||||
pub const CommandBuffer = @import("command_buffer.zig").CommandBuffer;
|
||||
pub const CommandEncoder = @import("CommandEncoder.zig");
|
||||
pub const ComputePassEncoder = @import("ComputePassEncoder.zig");
|
||||
pub const ComputePipeline = @import("ComputePipeline.zig");
|
||||
|
|
@ -41,7 +41,7 @@ test {
|
|||
refAllDecls(@import("bind_group.zig"));
|
||||
refAllDecls(@import("bind_group_layout.zig"));
|
||||
refAllDecls(@import("buffer.zig"));
|
||||
refAllDecls(@import("CommandBuffer.zig"));
|
||||
refAllDecls(@import("command_buffer.zig"));
|
||||
refAllDecls(@import("CommandEncoder.zig"));
|
||||
refAllDecls(@import("ComputePassEncoder.zig"));
|
||||
refAllDecls(@import("ComputePipeline.zig"));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue