gpu: add Sampler.BindingLayout
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
parent
e2ed25babc
commit
58c27b41a8
4 changed files with 13 additions and 14 deletions
|
|
@ -23,8 +23,21 @@ pub inline fn setLabel(sampler: Sampler, label: [:0]const u8) void {
|
||||||
sampler.vtable.setLabel(sampler.ptr, label);
|
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" {
|
test "syntax" {
|
||||||
_ = VTable;
|
_ = VTable;
|
||||||
_ = reference;
|
_ = reference;
|
||||||
_ = release;
|
_ = release;
|
||||||
|
_ = BindingType;
|
||||||
|
_ = BindingLayout;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -204,11 +204,6 @@ typedef struct WGPUCopyTextureForBrowserOptions {
|
||||||
WGPUAlphaMode dstAlphaMode;
|
WGPUAlphaMode dstAlphaMode;
|
||||||
} WGPUCopyTextureForBrowserOptions;
|
} WGPUCopyTextureForBrowserOptions;
|
||||||
|
|
||||||
typedef struct WGPUSamplerBindingLayout {
|
|
||||||
WGPUChainedStruct const * nextInChain;
|
|
||||||
WGPUSamplerBindingType type;
|
|
||||||
} WGPUSamplerBindingLayout;
|
|
||||||
|
|
||||||
typedef struct WGPUStorageTextureBindingLayout {
|
typedef struct WGPUStorageTextureBindingLayout {
|
||||||
WGPUChainedStruct const * nextInChain;
|
WGPUChainedStruct const * nextInChain;
|
||||||
WGPUStorageTextureAccess access;
|
WGPUStorageTextureAccess access;
|
||||||
|
|
|
||||||
|
|
@ -312,13 +312,6 @@ pub const RenderPassTimestampLocation = enum(u32) {
|
||||||
end = 0x00000001,
|
end = 0x00000001,
|
||||||
};
|
};
|
||||||
|
|
||||||
pub const SamplerBindingType = enum(u32) {
|
|
||||||
none = 0x00000000,
|
|
||||||
filtering = 0x00000001,
|
|
||||||
non_filtering = 0x00000002,
|
|
||||||
comparison = 0x00000003,
|
|
||||||
};
|
|
||||||
|
|
||||||
pub const StencilOperation = enum(u32) {
|
pub const StencilOperation = enum(u32) {
|
||||||
keep = 0x00000000,
|
keep = 0x00000000,
|
||||||
zero = 0x00000001,
|
zero = 0x00000001,
|
||||||
|
|
@ -489,7 +482,6 @@ test "syntax" {
|
||||||
_ = PrimitiveTopology;
|
_ = PrimitiveTopology;
|
||||||
_ = QueryType;
|
_ = QueryType;
|
||||||
_ = RenderPassTimestampLocation;
|
_ = RenderPassTimestampLocation;
|
||||||
_ = SamplerBindingType;
|
|
||||||
_ = StencilOperation;
|
_ = StencilOperation;
|
||||||
_ = StorageTextureAccess;
|
_ = StorageTextureAccess;
|
||||||
_ = StoreOp;
|
_ = StoreOp;
|
||||||
|
|
|
||||||
|
|
@ -123,7 +123,6 @@ pub const PredefinedColorSpace = @import("enums.zig").PredefinedColorSpace;
|
||||||
pub const PrimitiveTopology = @import("enums.zig").PrimitiveTopology;
|
pub const PrimitiveTopology = @import("enums.zig").PrimitiveTopology;
|
||||||
pub const QueryType = @import("enums.zig").QueryType;
|
pub const QueryType = @import("enums.zig").QueryType;
|
||||||
pub const RenderPassTimestampLocation = @import("enums.zig").RenderPassTimestampLocation;
|
pub const RenderPassTimestampLocation = @import("enums.zig").RenderPassTimestampLocation;
|
||||||
pub const SamplerBindingType = @import("enums.zig").SamplerBindingType;
|
|
||||||
pub const StencilOperation = @import("enums.zig").StencilOperation;
|
pub const StencilOperation = @import("enums.zig").StencilOperation;
|
||||||
pub const StorageTextureAccess = @import("enums.zig").StorageTextureAccess;
|
pub const StorageTextureAccess = @import("enums.zig").StorageTextureAccess;
|
||||||
pub const StoreOp = @import("enums.zig").StoreOp;
|
pub const StoreOp = @import("enums.zig").StoreOp;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue