Skip to content

Commit

Permalink
Update dawn.json.
Browse files Browse the repository at this point in the history
This CL syncs dawn.json to the changes added in
webgpu-native/webgpu-headers#203 and other minor differences to upstream webgpu.h.

Change-Id: I214a74325e405a3165dbf92b2f455b78377b81b3
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/147581
Kokoro: Kokoro <[email protected]>
Commit-Queue: Dan Sinclair <[email protected]>
Reviewed-by: Kai Ninomiya <[email protected]>
  • Loading branch information
dj2 authored and Dawn LUCI CQ committed Aug 21, 2023
1 parent d1dcb50 commit 3ebe5b6
Showing 1 changed file with 118 additions and 10 deletions.
128 changes: 118 additions & 10 deletions dawn.json
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,42 @@
{"name": "multisampled", "type": "bool", "default": "false"}
]
},

"surface capabilities": {
"category": "structure",
"tags": ["upstream"],
"extensible": "out",
"members": [
{"name": "format count", "type": "size_t"},
{"name": "formats", "type": "texture format", "annotation": "*"},
{"name": "present mode count", "type": "size_t"},
{"name": "present modes", "type": "present mode", "annotation": "*"},
{"name": "alpha mode count", "type": "size_t"},
{"name": "alpha modes", "type": "composite alpha mode", "annotation": "*"}
],
"methods": [
{
"name": "free members",
"returns": "void",
"args": []
}
]
},
"surface configuration": {
"category": "structure",
"tags": ["upstream"],
"extensible": "in",
"members": [
{"name": "device", "type": "device"},
{"name": "format", "type": "texture format"},
{"name": "usage", "type": "texture usage"},
{"name": "view format count", "type": "size_t"},
{"name": "view formats", "type": "texture format", "annotation": "const*"},
{"name": "alpha mode", "type": "composite alpha mode"},
{"name": "width", "type": "uint32_t"},
{"name": "height", "type": "uint32_t"},
{"name": "present mode", "type": "present mode"}
]
},
"external texture binding entry": {
"category": "structure",
"chained": "in",
Expand All @@ -340,8 +375,8 @@
"values": [
{"value": 0, "name": "undefined", "jsrepr": "undefined", "valid": false},
{"value": 1, "name": "write only"},
{"value": 2, "name": "read only"},
{"value": 3, "name": "read write"}
{"value": 2, "name": "read only", "tags": ["dawn"]},
{"value": 3, "name": "read write", "tags": ["dawn"]}
]
},
"storage texture binding layout": {
Expand Down Expand Up @@ -400,10 +435,10 @@
{"value": 10, "name": "src alpha saturated"},
{"value": 11, "name": "constant"},
{"value": 12, "name": "one minus constant"},
{"value": 13, "name": "src1"},
{"value": 14, "name": "one minus src1"},
{"value": 15, "name": "src1 alpha"},
{"value": 16, "name": "one minus src1 alpha"}
{"value": 13, "name": "src1", "tags": ["dawn"]},
{"value": 14, "name": "one minus src1", "tags": ["dawn"]},
{"value": 15, "name": "src1 alpha", "tags": ["dawn"]},
{"value": 16, "name": "one minus src1 alpha", "tags": ["dawn"]}
]
},
"blend operation": {
Expand Down Expand Up @@ -868,6 +903,17 @@
}
]
},
"composite alpha mode": {
"category": "enum",
"tags": ["upstream"],
"values": [
{"value": 0, "name": "auto"},
{"value": 1, "name": "opaque"},
{"value": 2, "name": "premultiplied"},
{"value": 3, "name": "unpremultiplied"},
{"value": 4, "name": "inherit"}
]
},
"compute pass timestamp location": {
"category": "enum",
"values": [
Expand Down Expand Up @@ -1106,6 +1152,7 @@
},
{
"name": "create swap chain",
"tags": ["dawn", "emscripten"],
"returns": "swap chain",
"args": [
{"name": "surface", "type": "surface"},
Expand Down Expand Up @@ -2051,9 +2098,10 @@
"category": "enum",
"emscripten_no_enum_table": true,
"values": [
{"value": 0, "name": "immediate"},
{"value": 1, "name": "mailbox"},
{"value": 2, "name": "fifo"}
{"value": 0, "name": "fifo"},
{"value": 1, "name": "fifo relaxed", "tags": ["upstream"]},
{"value": 2, "name": "immediate"},
{"value": 3, "name": "mailbox"}
]
},
"programmable stage descriptor": {
Expand Down Expand Up @@ -2907,13 +2955,50 @@
"category": "object",
"no autolock": true,
"methods": [
{
"name": "configure",
"returns": "void",
"tags": ["upstream"],
"args": [
{"name": "config", "type": "surface configuration", "annotation": "const*"}
]
},
{
"name": "get capabilities",
"returns": "void",
"tags": ["upstream"],
"args": [
{"name": "adapter", "type": "adapter"},
{"name": "capabilities", "type": "surface capabilities", "annotation": "*"}
]
},
{
"name": "get current texture",
"returns": "void",
"tags": ["upstream"],
"args": [
{"name": "surface texture", "type": "surface texture", "annotation": "*"}
]
},
{
"name": "get preferred format",
"returns": "texture format",
"tags": ["upstream", "emscripten"],
"args": [
{"name": "adapter", "type": "adapter"}
]
},
{
"name": "present",
"returns": "void",
"tags": ["upstream"],
"args": []
},
{
"name": "unconfigure",
"returns": "void",
"tags": ["upstream"],
"args": []
}
]
},
Expand Down Expand Up @@ -3010,6 +3095,7 @@
},
"swap chain": {
"category": "object",
"tags": ["dawn", "emscripten"],
"methods": [
{"name": "get current texture view", "returns": "texture view"},
{"name": "get current texture", "returns": "texture", "tags": ["dawn"]},
Expand All @@ -3018,6 +3104,7 @@
},
"swap chain descriptor": {
"category": "structure",
"tags": ["dawn", "emscripten"],
"extensible": "in",
"members": [
{"name": "label", "type": "char", "annotation": "const*", "length": "strlen", "optional": true},
Expand All @@ -3028,6 +3115,15 @@
{"name": "present mode", "type": "present mode"}
]
},
"surface texture": {
"category": "structure",
"tags": ["upstream"],
"members": [
{"name": "texture", "type": "texture"},
{"name": "suboptimal", "type": "bool"},
{"name": "status", "type": "surface get current texture status"}
]
},
"s type": {
"category": "enum",
"emscripten_no_enum_table": true,
Expand Down Expand Up @@ -3143,6 +3239,18 @@
}
]
},
"surface get current texture status": {
"category": "enum",
"tags": ["upstream"],
"values": [
{"value": 0, "name": "success"},
{"value": 1, "name": "timeout"},
{"value": 2, "name": "outdated"},
{"value": 3, "name": "lost"},
{"value": 4, "name": "out of memory"},
{"value": 5, "name": "device lost"}
]
},
"texture aspect": {
"category": "enum",
"values": [
Expand Down

0 comments on commit 3ebe5b6

Please sign in to comment.