Skip to content

Commit 931e445

Browse files
Add depthSlice to WGPURenderPassColorAttachment
1 parent 6e54690 commit 931e445

File tree

6 files changed

+17
-8
lines changed

6 files changed

+17
-8
lines changed

src/generated_struct_info32.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1081,10 +1081,11 @@
10811081
"WGPURenderPassColorAttachment": {
10821082
"__size__": 56,
10831083
"clearValue": 24,
1084-
"loadOp": 12,
1084+
"depthSlice": 8,
1085+
"loadOp": 16,
10851086
"nextInChain": 0,
1086-
"resolveTarget": 8,
1087-
"storeOp": 16,
1087+
"resolveTarget": 12,
1088+
"storeOp": 20,
10881089
"view": 4
10891090
},
10901091
"WGPURenderPassDepthStencilAttachment": {

src/generated_struct_info64.json

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1079,12 +1079,13 @@
10791079
"stencilReadOnly": 41
10801080
},
10811081
"WGPURenderPassColorAttachment": {
1082-
"__size__": 64,
1083-
"clearValue": 32,
1084-
"loadOp": 24,
1082+
"__size__": 72,
1083+
"clearValue": 40,
1084+
"depthSlice": 16,
1085+
"loadOp": 32,
10851086
"nextInChain": 0,
1086-
"resolveTarget": 16,
1087-
"storeOp": 28,
1087+
"resolveTarget": 24,
1088+
"storeOp": 36,
10881089
"view": 8
10891090
},
10901091
"WGPURenderPassDepthStencilAttachment": {

src/struct_info.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1538,6 +1538,7 @@
15381538
"WGPURenderPassColorAttachment": [
15391539
"nextInChain",
15401540
"view",
1541+
"depthSlice",
15411542
"resolveTarget",
15421543
"loadOp",
15431544
"storeOp",

system/include/webgpu/webgpu.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@
7070

7171
#define WGPU_ARRAY_LAYER_COUNT_UNDEFINED (0xffffffffUL)
7272
#define WGPU_COPY_STRIDE_UNDEFINED (0xffffffffUL)
73+
#define WGPU_DEPTH_SLICE_UNDEFINED (0xffffffffUL)
7374
#define WGPU_LIMIT_U32_UNDEFINED (0xffffffffUL)
7475
#define WGPU_LIMIT_U64_UNDEFINED (0xffffffffffffffffULL)
7576
#define WGPU_MIP_LEVEL_COUNT_UNDEFINED (0xffffffffUL)
@@ -1120,6 +1121,7 @@ typedef struct WGPUProgrammableStageDescriptor {
11201121
typedef struct WGPURenderPassColorAttachment {
11211122
WGPUChainedStruct const * nextInChain;
11221123
WGPU_NULLABLE WGPUTextureView view;
1124+
uint32_t depthSlice;
11231125
WGPU_NULLABLE WGPUTextureView resolveTarget;
11241126
WGPULoadOp loadOp;
11251127
WGPUStoreOp storeOp;

system/include/webgpu/webgpu_cpp.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,7 @@ namespace wgpu {
136136

137137
static constexpr uint32_t kArrayLayerCountUndefined = WGPU_ARRAY_LAYER_COUNT_UNDEFINED;
138138
static constexpr uint32_t kCopyStrideUndefined = WGPU_COPY_STRIDE_UNDEFINED;
139+
static constexpr uint32_t kDepthSliceUndefined = WGPU_DEPTH_SLICE_UNDEFINED;
139140
static constexpr uint32_t kLimitU32Undefined = WGPU_LIMIT_U32_UNDEFINED;
140141
static constexpr uint64_t kLimitU64Undefined = WGPU_LIMIT_U64_UNDEFINED;
141142
static constexpr uint32_t kMipLevelCountUndefined = WGPU_MIP_LEVEL_COUNT_UNDEFINED;
@@ -1647,6 +1648,7 @@ namespace wgpu {
16471648
struct RenderPassColorAttachment {
16481649
ChainedStruct const * nextInChain = nullptr;
16491650
TextureView view = nullptr;
1651+
uint32_t depthSlice = WGPU_DEPTH_SLICE_UNDEFINED;
16501652
TextureView resolveTarget = nullptr;
16511653
LoadOp loadOp;
16521654
StoreOp storeOp;

system/lib/webgpu/webgpu_cpp.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1424,6 +1424,8 @@ namespace wgpu {
14241424
"offsetof mismatch for RenderPassColorAttachment::nextInChain");
14251425
static_assert(offsetof(RenderPassColorAttachment, view) == offsetof(WGPURenderPassColorAttachment, view),
14261426
"offsetof mismatch for RenderPassColorAttachment::view");
1427+
static_assert(offsetof(RenderPassColorAttachment, depthSlice) == offsetof(WGPURenderPassColorAttachment, depthSlice),
1428+
"offsetof mismatch for RenderPassColorAttachment::depthSlice");
14271429
static_assert(offsetof(RenderPassColorAttachment, resolveTarget) == offsetof(WGPURenderPassColorAttachment, resolveTarget),
14281430
"offsetof mismatch for RenderPassColorAttachment::resolveTarget");
14291431
static_assert(offsetof(RenderPassColorAttachment, loadOp) == offsetof(WGPURenderPassColorAttachment, loadOp),

0 commit comments

Comments
 (0)