From 8f2f6d5789d691ff3275523efee16113b62f85eb Mon Sep 17 00:00:00 2001 From: Stephen Gutekanst Date: Wed, 27 Jul 2022 09:50:04 -0700 Subject: [PATCH] gpu: update defaults/optionality for RenderPassDepthStencilAttachment Signed-off-by: Stephen Gutekanst --- gpu/src/main.zig | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/gpu/src/main.zig b/gpu/src/main.zig index 2136bb89..2f30b61e 100644 --- a/gpu/src/main.zig +++ b/gpu/src/main.zig @@ -75,16 +75,16 @@ pub const ComputePassTimestampWrite = extern struct { pub const RenderPassDepthStencilAttachment = extern struct { view: texture_view.TextureView, - depth_load_op: types.LoadOp, - depth_store_op: types.StoreOp, - clear_depth: f32, - depth_clear_value: f32, - depth_read_only: bool, - stencil_load_op: types.LoadOp, - stencil_store_op: types.StoreOp, - clear_stencil: u32, - stencil_clear_value: u32, - stencil_read_only: bool, + depth_load_op: types.LoadOp = .undef, + depth_store_op: types.StoreOp = .undef, + clear_depth: f32 = std.math.nan(f32), // deprecated + depth_clear_value: f32 = 0, + depth_read_only: bool = false, + stencil_load_op: types.LoadOp = .undef, + stencil_store_op: types.StoreOp = .undef, + clear_stencil: u32 = 0, // deprecated + stencil_clear_value: u32 = 0, + stencil_read_only: bool = false, }; pub const RenderPassTimestampWrite = extern struct {