gpu: add Sampler.BindingLayout

Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
Stephen Gutekanst 2022-03-11 15:39:05 -07:00 committed by Stephen Gutekanst
parent e2ed25babc
commit 58c27b41a8
4 changed files with 13 additions and 14 deletions

View file

@ -23,8 +23,21 @@ pub inline fn setLabel(sampler: Sampler, label: [:0]const u8) void {
sampler.vtable.setLabel(sampler.ptr, label);
}
pub const BindingType = enum(u32) {
none = 0x00000000,
filtering = 0x00000001,
non_filtering = 0x00000002,
comparison = 0x00000003,
};
pub const BindingLayout = struct {
type: BindingType,
};
test "syntax" {
_ = VTable;
_ = reference;
_ = release;
_ = BindingType;
_ = BindingLayout;
}

View file

@ -204,11 +204,6 @@ typedef struct WGPUCopyTextureForBrowserOptions {
WGPUAlphaMode dstAlphaMode;
} WGPUCopyTextureForBrowserOptions;
typedef struct WGPUSamplerBindingLayout {
WGPUChainedStruct const * nextInChain;
WGPUSamplerBindingType type;
} WGPUSamplerBindingLayout;
typedef struct WGPUStorageTextureBindingLayout {
WGPUChainedStruct const * nextInChain;
WGPUStorageTextureAccess access;

View file

@ -312,13 +312,6 @@ pub const RenderPassTimestampLocation = enum(u32) {
end = 0x00000001,
};
pub const SamplerBindingType = enum(u32) {
none = 0x00000000,
filtering = 0x00000001,
non_filtering = 0x00000002,
comparison = 0x00000003,
};
pub const StencilOperation = enum(u32) {
keep = 0x00000000,
zero = 0x00000001,
@ -489,7 +482,6 @@ test "syntax" {
_ = PrimitiveTopology;
_ = QueryType;
_ = RenderPassTimestampLocation;
_ = SamplerBindingType;
_ = StencilOperation;
_ = StorageTextureAccess;
_ = StoreOp;

View file

@ -123,7 +123,6 @@ pub const PredefinedColorSpace = @import("enums.zig").PredefinedColorSpace;
pub const PrimitiveTopology = @import("enums.zig").PrimitiveTopology;
pub const QueryType = @import("enums.zig").QueryType;
pub const RenderPassTimestampLocation = @import("enums.zig").RenderPassTimestampLocation;
pub const SamplerBindingType = @import("enums.zig").SamplerBindingType;
pub const StencilOperation = @import("enums.zig").StencilOperation;
pub const StorageTextureAccess = @import("enums.zig").StorageTextureAccess;
pub const StoreOp = @import("enums.zig").StoreOp;