Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Define depthWriteEnabled as WGPUOptionalBool #308

Merged
merged 3 commits into from
Jul 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion webgpu.h
Original file line number Diff line number Diff line change
Expand Up @@ -438,6 +438,13 @@ typedef enum WGPUMipmapFilterMode {
WGPUMipmapFilterMode_Force32 = 0x7FFFFFFF
} WGPUMipmapFilterMode WGPU_ENUM_ATTRIBUTE;

typedef enum WGPUOptionalBool {
WGPUOptionalBool_False = 0x00000000,
WGPUOptionalBool_True = 0x00000001,
WGPUOptionalBool_Undefined = 0x00000002,
WGPUOptionalBool_Force32 = 0x7FFFFFFF
} WGPUOptionalBool WGPU_ENUM_ATTRIBUTE;

typedef enum WGPUPopErrorScopeStatus {
WGPUPopErrorScopeStatus_Success = 0x00000001,
WGPUPopErrorScopeStatus_InstanceDropped = 0x00000002,
Expand Down Expand Up @@ -1355,7 +1362,7 @@ typedef struct WGPUComputePassDescriptor {
typedef struct WGPUDepthStencilState {
WGPUChainedStruct const * nextInChain;
WGPUTextureFormat format;
WGPUBool depthWriteEnabled;
WGPUOptionalBool depthWriteEnabled;
WGPUCompareFunction depthCompare;
WGPUStencilFaceState stencilFront;
WGPUStencilFaceState stencilBack;
Expand Down
15 changes: 14 additions & 1 deletion webgpu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -548,6 +548,19 @@ enums:
- name: linear
doc: |
TODO
- name: optional_bool
doc: |
TODO
entries:
- name: "false"
doc: |
TODO
- name: "true"
doc: |
TODO
- name: undefined
doc: |
TODO
- name: pop_error_scope_status
doc: |
TODO
Expand Down Expand Up @@ -1822,7 +1835,7 @@ structs:
- name: depth_write_enabled
doc: |
TODO
type: bool
type: enum.optional_bool
- name: depth_compare
doc: |
TODO
Expand Down
Loading