gpu: add Color
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
parent
5bce559ce4
commit
a7b0a50dd4
3 changed files with 10 additions and 9 deletions
|
|
@ -351,13 +351,6 @@ typedef struct WGPUFragmentState {
|
|||
|
||||
|
||||
|
||||
typedef struct WGPUColor {
|
||||
double r;
|
||||
double g;
|
||||
double b;
|
||||
double a;
|
||||
} WGPUColor;
|
||||
|
||||
typedef struct WGPUComputePassTimestampWrite {
|
||||
WGPUQuerySet querySet;
|
||||
uint32_t queryIndex;
|
||||
|
|
|
|||
|
|
@ -77,6 +77,7 @@ pub const ComputePipeline = @import("ComputePipeline.zig");
|
|||
// Data structures
|
||||
pub const Limits = @import("structs.zig").Limits;
|
||||
pub const BlendComponent = @import("structs.zig").BlendComponent;
|
||||
pub const Color = @import("structs.zig").Color;
|
||||
|
||||
// Enumerations
|
||||
pub const Feature = @import("enums.zig").Feature;
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ const BlendOperation = @import("enums.zig").BlendOperation;
|
|||
const BlendFactor = @import("enums.zig").BlendFactor;
|
||||
|
||||
// TODO: docs
|
||||
pub const Limits = struct {
|
||||
pub const Limits = extern struct {
|
||||
max_texture_dimension_1d: u32,
|
||||
max_texture_dimension_2d: u32,
|
||||
max_texture_dimension_3d: u32,
|
||||
|
|
@ -31,8 +31,15 @@ pub const Limits = struct {
|
|||
max_compute_workgroups_per_dimension: u32,
|
||||
};
|
||||
|
||||
pub const BlendComponent = struct {
|
||||
pub const BlendComponent = extern struct {
|
||||
operation: BlendOperation,
|
||||
src_factor: BlendFactor,
|
||||
dst_factor: BlendFactor,
|
||||
};
|
||||
|
||||
pub const Color = extern struct {
|
||||
r: f64,
|
||||
g: f64,
|
||||
b: f64,
|
||||
a: f64,
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue