2017-05-31 00:03:44 +00:00
|
|
|
{
|
|
|
|
"_comment": [
|
|
|
|
"Copyright 2017 The NXT Authors",
|
|
|
|
"",
|
|
|
|
"Licensed under the Apache License, Version 2.0 (the \"License\");",
|
|
|
|
"you may not use this file except in compliance with the License.",
|
|
|
|
"You may obtain a copy of the License at",
|
|
|
|
"",
|
|
|
|
" http://www.apache.org/licenses/LICENSE-2.0",
|
|
|
|
"",
|
|
|
|
"Unless required by applicable law or agreed to in writing, software",
|
|
|
|
"distributed under the License is distributed on an \"AS IS\" BASIS,",
|
|
|
|
"WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.",
|
|
|
|
"See the License for the specific language governing permissions and",
|
|
|
|
"limitations under the License."
|
|
|
|
],
|
2017-06-01 15:30:03 +00:00
|
|
|
"bool": {
|
|
|
|
"category": "native"
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
"bind group": {
|
|
|
|
"category": "object"
|
|
|
|
},
|
|
|
|
"bind group builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "bind group"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set layout",
|
|
|
|
"args": [
|
|
|
|
{"name": "layout", "type": "bind group layout"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set usage",
|
|
|
|
"args": [
|
|
|
|
{"name": "usage", "type": "bind group usage"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set buffer views",
|
|
|
|
"args": [
|
|
|
|
{"name": "start", "type": "uint32_t"},
|
|
|
|
{"name": "count", "type": "uint32_t"},
|
|
|
|
{"name": "buffer views", "type": "buffer view", "annotation": "const*", "length": "count"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set samplers",
|
|
|
|
"args": [
|
|
|
|
{"name": "start", "type": "uint32_t"},
|
|
|
|
{"name": "count", "type": "uint32_t"},
|
|
|
|
{"name": "samplers", "type": "sampler", "annotation": "const*", "length": "count"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set texture views",
|
|
|
|
"args": [
|
|
|
|
{"name": "start", "type": "uint32_t"},
|
|
|
|
{"name": "count", "type": "uint32_t"},
|
|
|
|
{"name": "texture views", "type": "texture view", "annotation": "const*", "length": "count"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"TODO": [
|
|
|
|
"When resource are added, add methods for setting the content of the bind group"
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"bind group usage": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "frozen"},
|
|
|
|
{"value": 1, "name": "dynamic"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"bind group layout": {
|
|
|
|
"category": "object"
|
|
|
|
},
|
|
|
|
"bind group layout builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "bind group layout"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set bindings type",
|
|
|
|
"args": [
|
|
|
|
{"name": "visibility", "type": "shader stage bit"},
|
|
|
|
{"name": "binding type", "type": "binding type"},
|
|
|
|
{"name": "start", "type": "uint32_t"},
|
|
|
|
{"name": "count", "type": "uint32_t"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"binding type": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "uniform buffer"},
|
|
|
|
{"value": 1, "name": "sampler"},
|
|
|
|
{"value": 2, "name": "sampled texture"},
|
|
|
|
{"value": 3, "name": "storage buffer"}
|
|
|
|
]
|
|
|
|
},
|
2017-07-26 20:59:53 +00:00
|
|
|
"blend factor": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "zero"},
|
|
|
|
{"value": 1, "name": "one"},
|
|
|
|
{"value": 2, "name": "src color"},
|
|
|
|
{"value": 3, "name": "one minus src color"},
|
|
|
|
{"value": 4, "name": "src alpha"},
|
|
|
|
{"value": 5, "name": "one minus src alpha"},
|
|
|
|
{"value": 6, "name": "dst color"},
|
|
|
|
{"value": 7, "name": "one minus dst color"},
|
|
|
|
{"value": 8, "name": "dst alpha"},
|
|
|
|
{"value": 9, "name": "one minus dst alpha"},
|
|
|
|
{"value": 10, "name": "src alpha saturated"},
|
|
|
|
{"value": 11, "name": "blend color"},
|
2017-08-03 20:24:49 +00:00
|
|
|
{"value": 12, "name": "one minus blend color"}
|
2017-07-26 20:59:53 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
"blend operation": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "add"},
|
|
|
|
{"value": 1, "name": "subtract"},
|
|
|
|
{"value": 2, "name": "reverse subtract"},
|
|
|
|
{"value": 3, "name": "min"},
|
|
|
|
{"value": 4, "name": "max"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"blend state": {
|
|
|
|
"category": "object"
|
|
|
|
},
|
|
|
|
"blend state builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "blend state"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set blend enabled",
|
|
|
|
"args": [
|
|
|
|
{"name": "blend enabled", "type": "bool"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set alpha blend",
|
|
|
|
"args": [
|
|
|
|
{"name": "blend operation", "type": "blend operation"},
|
|
|
|
{"name": "src factor", "type": "blend factor"},
|
|
|
|
{"name": "dst factor", "type": "blend factor"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set color blend",
|
|
|
|
"args": [
|
|
|
|
{"name": "blend operation", "type": "blend operation"},
|
|
|
|
{"name": "src factor", "type": "blend factor"},
|
|
|
|
{"name": "dst factor", "type": "blend factor"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set color write mask",
|
|
|
|
"args": [
|
|
|
|
{"name": "color write mask", "type": "color write mask"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
"builder error status": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "success"},
|
|
|
|
{"value": 1, "name": "error", "TODO": "cwallez@chromium.org: recoverable errors like GPU OOM"},
|
|
|
|
{"value": 2, "name": "unknown"},
|
|
|
|
{"value": 3, "name": "context lost"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"builder error callback": {
|
|
|
|
"category": "natively defined"
|
|
|
|
},
|
|
|
|
"buffer": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "create buffer view builder",
|
|
|
|
"returns": "buffer view builder"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set sub data",
|
|
|
|
"args": [
|
|
|
|
{"name": "start", "type": "uint32_t"},
|
|
|
|
{"name": "count", "type": "uint32_t"},
|
2018-02-04 16:07:02 +00:00
|
|
|
{"name": "data", "type": "uint8_t", "annotation": "const*", "length": "count"}
|
2017-05-31 00:03:44 +00:00
|
|
|
]
|
|
|
|
},
|
2017-06-09 14:51:29 +00:00
|
|
|
{
|
|
|
|
"_comment": "Contrary to set sub data, this is in char size",
|
|
|
|
"name": "map read async",
|
|
|
|
"args": [
|
|
|
|
{"name": "start", "type": "uint32_t"},
|
|
|
|
{"name": "size", "type": "uint32_t"},
|
|
|
|
{"name": "callback", "type": "buffer map read callback"},
|
|
|
|
{"name": "userdata", "type": "callback userdata"}
|
|
|
|
]
|
|
|
|
},
|
2018-03-21 00:56:39 +00:00
|
|
|
{
|
|
|
|
"_comment": "Contrary to set sub data, this is in char size",
|
|
|
|
"name": "map write async",
|
|
|
|
"args": [
|
|
|
|
{"name": "start", "type": "uint32_t"},
|
|
|
|
{"name": "size", "type": "uint32_t"},
|
|
|
|
{"name": "callback", "type": "buffer map write callback"},
|
|
|
|
{"name": "userdata", "type": "callback userdata"}
|
|
|
|
]
|
|
|
|
},
|
2017-06-09 14:51:29 +00:00
|
|
|
{
|
|
|
|
"name": "unmap"
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
{
|
|
|
|
"name": "transition usage",
|
|
|
|
"args": [
|
|
|
|
{"name": "usage", "type": "buffer usage bit"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "freeze usage",
|
|
|
|
"args": [
|
|
|
|
{"name": "usage", "type": "buffer usage bit"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"buffer builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "buffer"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set allowed usage",
|
|
|
|
"args": [
|
|
|
|
{"name": "usage", "type": "buffer usage bit"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set initial usage",
|
|
|
|
"args": [
|
|
|
|
{"name": "usage", "type": "buffer usage bit"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set size",
|
|
|
|
"args": [
|
|
|
|
{"name": "size", "type": "uint32_t"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2017-06-09 14:51:29 +00:00
|
|
|
"buffer map read callback": {
|
|
|
|
"category": "natively defined"
|
|
|
|
},
|
2018-03-21 00:56:39 +00:00
|
|
|
"buffer map write callback": {
|
|
|
|
"category": "natively defined"
|
|
|
|
},
|
2018-03-20 23:48:54 +00:00
|
|
|
"buffer map async status": {
|
2017-06-09 14:51:29 +00:00
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "success"},
|
|
|
|
{"value": 1, "name": "error"},
|
|
|
|
{"value": 2, "name": "unknown"},
|
|
|
|
{"value": 3, "name": "context lost"}
|
|
|
|
]
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
"buffer usage bit": {
|
|
|
|
"category": "bitmask",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "none"},
|
2017-06-05 19:42:14 +00:00
|
|
|
{"value": 1, "name": "map read"},
|
2017-06-16 19:35:12 +00:00
|
|
|
{"value": 2, "name": "map write"},
|
|
|
|
{"value": 4, "name": "transfer src"},
|
|
|
|
{"value": 8, "name": "transfer dst"},
|
|
|
|
{"value": 16, "name": "index"},
|
|
|
|
{"value": 32, "name": "vertex"},
|
|
|
|
{"value": 64, "name": "uniform"},
|
|
|
|
{"value": 128, "name": "storage"}
|
2017-05-31 00:03:44 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
"buffer view": {
|
|
|
|
"category": "object"
|
|
|
|
},
|
|
|
|
"buffer view builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "buffer view"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set extent",
|
|
|
|
"args": [
|
|
|
|
{"name": "offset", "type": "uint32_t"},
|
|
|
|
{"name": "size", "type": "uint32_t"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"callback userdata": {
|
|
|
|
"category": "natively defined"
|
|
|
|
},
|
|
|
|
"char": {
|
|
|
|
"category": "native"
|
|
|
|
},
|
2017-07-26 20:59:53 +00:00
|
|
|
"color write mask": {
|
|
|
|
"category": "bitmask",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "none"},
|
|
|
|
{"value": 1, "name": "red"},
|
|
|
|
{"value": 2, "name": "green"},
|
|
|
|
{"value": 4, "name": "blue"},
|
|
|
|
{"value": 8, "name": "alpha"},
|
|
|
|
{"value": 15, "name": "all"}
|
|
|
|
]
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
"command buffer": {
|
|
|
|
"category": "object"
|
|
|
|
},
|
|
|
|
"command buffer builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "command buffer"
|
|
|
|
},
|
2017-07-10 21:07:24 +00:00
|
|
|
{
|
|
|
|
"name": "begin compute pass"
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
{
|
|
|
|
"name": "begin render pass",
|
|
|
|
"args": [
|
2018-05-11 17:04:44 +00:00
|
|
|
{"name": "info", "type": "render pass descriptor"}
|
2017-05-31 00:03:44 +00:00
|
|
|
]
|
|
|
|
},
|
2017-06-12 22:12:29 +00:00
|
|
|
{
|
|
|
|
"name": "copy buffer to buffer",
|
|
|
|
"args": [
|
|
|
|
{"name": "source", "type": "buffer"},
|
|
|
|
{"name": "source offset", "type": "uint32_t"},
|
|
|
|
{"name": "destination", "type": "buffer"},
|
|
|
|
{"name": "destination offset", "type": "uint32_t"},
|
|
|
|
{"name": "size", "type": "uint32_t"}
|
|
|
|
],
|
|
|
|
"TODO": [
|
|
|
|
"Restrictions on the alignment of the copy? Cf Metal on OSX"
|
|
|
|
]
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
{
|
|
|
|
"name": "copy buffer to texture",
|
|
|
|
"args": [
|
|
|
|
{"name": "buffer", "type": "buffer"},
|
|
|
|
{"name": "buffer offset", "type": "uint32_t"},
|
2017-07-13 14:04:23 +00:00
|
|
|
{"name": "row pitch", "type": "uint32_t"},
|
2017-05-31 00:03:44 +00:00
|
|
|
{"name": "texture", "type": "texture"},
|
|
|
|
{"name": "x", "type": "uint32_t"},
|
|
|
|
{"name": "y", "type": "uint32_t"},
|
|
|
|
{"name": "z", "type": "uint32_t"},
|
|
|
|
{"name": "width", "type": "uint32_t"},
|
|
|
|
{"name": "height", "type": "uint32_t"},
|
|
|
|
{"name": "depth", "type": "uint32_t"},
|
|
|
|
{"name": "level", "type": "uint32_t"}
|
|
|
|
],
|
|
|
|
"TODO": [
|
|
|
|
"Make pretty with Offset and Extents structures",
|
|
|
|
"Allow choosing the aspect (depth vs. stencil)?",
|
2017-06-26 20:23:03 +00:00
|
|
|
"Add these arguments too",
|
|
|
|
{"name": "image height", "type": "uint32_t"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "copy texture to buffer",
|
|
|
|
"args": [
|
|
|
|
{"name": "texture", "type": "texture"},
|
|
|
|
{"name": "x", "type": "uint32_t"},
|
|
|
|
{"name": "y", "type": "uint32_t"},
|
|
|
|
{"name": "z", "type": "uint32_t"},
|
|
|
|
{"name": "width", "type": "uint32_t"},
|
|
|
|
{"name": "height", "type": "uint32_t"},
|
|
|
|
{"name": "depth", "type": "uint32_t"},
|
|
|
|
{"name": "level", "type": "uint32_t"},
|
|
|
|
{"name": "buffer", "type": "buffer"},
|
2017-07-13 14:04:23 +00:00
|
|
|
{"name": "buffer offset", "type": "uint32_t"},
|
|
|
|
{"name": "row pitch", "type": "uint32_t"}
|
2017-06-26 20:23:03 +00:00
|
|
|
],
|
|
|
|
"TODO": [
|
|
|
|
"Make pretty with Offset and Extents structures",
|
|
|
|
"Allow choosing the aspect (depth vs. stencil)?",
|
2017-05-31 00:03:44 +00:00
|
|
|
"Add these arguments too",
|
|
|
|
{"name": "image height", "type": "uint32_t"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "dispatch",
|
|
|
|
"args": [
|
|
|
|
{"name": "x", "type": "uint32_t"},
|
|
|
|
{"name": "y", "type": "uint32_t"},
|
|
|
|
{"name": "z", "type": "uint32_t"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "draw arrays",
|
|
|
|
"args": [
|
|
|
|
{"name": "vertex count", "type": "uint32_t"},
|
|
|
|
{"name": "instance count", "type": "uint32_t"},
|
|
|
|
{"name": "first vertex", "type": "uint32_t"},
|
|
|
|
{"name": "first instance", "type": "uint32_t"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "draw elements",
|
|
|
|
"args": [
|
|
|
|
{"name": "index count", "type": "uint32_t"},
|
|
|
|
{"name": "instance count", "type": "uint32_t"},
|
|
|
|
{"name": "first index", "type": "uint32_t"},
|
|
|
|
{"name": "first instance", "type": "uint32_t"}
|
|
|
|
]
|
|
|
|
},
|
2017-07-10 21:07:24 +00:00
|
|
|
{
|
|
|
|
"name": "end compute pass"
|
|
|
|
},
|
2017-06-30 06:53:08 +00:00
|
|
|
{
|
|
|
|
"name": "end render pass"
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
{
|
|
|
|
"name": "set stencil reference",
|
|
|
|
"args": [
|
2017-06-01 15:30:03 +00:00
|
|
|
{"name": "reference", "type": "uint32_t"}
|
2017-05-31 00:03:44 +00:00
|
|
|
]
|
|
|
|
},
|
2017-08-01 18:22:52 +00:00
|
|
|
{
|
|
|
|
"name": "set blend color",
|
|
|
|
"args": [
|
|
|
|
{"name": "r", "type": "float"},
|
|
|
|
{"name": "g", "type": "float"},
|
|
|
|
{"name": "b", "type": "float"},
|
|
|
|
{"name": "a", "type": "float"}
|
|
|
|
]
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
{
|
|
|
|
"name": "set bind group",
|
|
|
|
"args": [
|
|
|
|
{"name": "group index", "type": "uint32_t"},
|
|
|
|
{"name": "group", "type": "bind group"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set index buffer",
|
|
|
|
"args": [
|
|
|
|
{"name": "buffer", "type": "buffer"},
|
2017-09-19 17:38:05 +00:00
|
|
|
{"name": "offset", "type": "uint32_t"}
|
2017-05-31 00:03:44 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set push constants",
|
|
|
|
"TODO": [
|
|
|
|
"data should be void*",
|
|
|
|
"TODO Vulkan has an additional stage mask"
|
|
|
|
],
|
|
|
|
"args": [
|
2017-07-20 15:01:37 +00:00
|
|
|
{"name": "stages", "type": "shader stage bit"},
|
2017-05-31 00:03:44 +00:00
|
|
|
{"name": "offset", "type": "uint32_t"},
|
|
|
|
{"name": "count", "type": "uint32_t"},
|
|
|
|
{"name": "data", "type": "uint32_t", "annotation": "const*", "length": "count"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
2017-07-14 14:58:07 +00:00
|
|
|
"name": "set compute pipeline",
|
2017-05-31 00:03:44 +00:00
|
|
|
"args": [
|
2017-07-14 14:58:07 +00:00
|
|
|
{"name": "pipeline", "type": "compute pipeline"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set render pipeline",
|
|
|
|
"args": [
|
|
|
|
{"name": "pipeline", "type": "render pipeline"}
|
2017-05-31 00:03:44 +00:00
|
|
|
]
|
|
|
|
},
|
2018-02-13 19:57:13 +00:00
|
|
|
{
|
|
|
|
"name": "set scissor rect",
|
|
|
|
"args": [
|
|
|
|
{"name": "x", "type": "uint32_t"},
|
|
|
|
{"name": "y", "type": "uint32_t"},
|
|
|
|
{"name": "width", "type": "uint32_t"},
|
|
|
|
{"name": "height", "type": "uint32_t"}
|
|
|
|
]
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
{
|
|
|
|
"name": "set vertex buffers",
|
|
|
|
"args": [
|
|
|
|
{"name": "start slot", "type": "uint32_t"},
|
|
|
|
{"name": "count", "type": "uint32_t"},
|
|
|
|
{"name": "buffers", "type": "buffer", "annotation": "const*", "length": "count"},
|
|
|
|
{"name": "offsets", "type": "uint32_t", "annotation": "const*", "length": "count"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "transition buffer usage",
|
|
|
|
"args": [
|
|
|
|
{"name": "buffer", "type": "buffer"},
|
|
|
|
{"name": "usage", "type": "buffer usage bit"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "transition texture usage",
|
|
|
|
"args": [
|
|
|
|
{"name": "texture", "type": "texture"},
|
|
|
|
{"name": "usage", "type": "texture usage bit"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"compare function": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "never"},
|
|
|
|
{"value": 1, "name": "less"},
|
|
|
|
{"value": 2, "name": "less equal"},
|
|
|
|
{"value": 3, "name": "greater"},
|
|
|
|
{"value": 4, "name": "greater equal"},
|
|
|
|
{"value": 5, "name": "equal"},
|
|
|
|
{"value": 6, "name": "not equal"},
|
|
|
|
{"value": 7, "name": "always"}
|
|
|
|
]
|
|
|
|
},
|
2017-07-14 14:58:07 +00:00
|
|
|
"compute pipeline": {
|
|
|
|
"category": "object"
|
|
|
|
},
|
|
|
|
"compute pipeline builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "compute pipeline"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set layout",
|
|
|
|
"args": [
|
|
|
|
{"name": "layout", "type": "pipeline layout"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set stage",
|
|
|
|
"args": [
|
|
|
|
{"name": "stage", "type": "shader stage"},
|
|
|
|
{"name": "module", "type": "shader module"},
|
|
|
|
{"name": "entry point", "type": "char", "annotation": "const*", "length": "strlen"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
"device": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "create bind group builder",
|
|
|
|
"returns": "bind group builder"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "create bind group layout builder",
|
|
|
|
"returns": "bind group layout builder"
|
|
|
|
},
|
2017-07-26 20:59:53 +00:00
|
|
|
{
|
|
|
|
"name": "create blend state builder",
|
|
|
|
"returns": "blend state builder"
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
{
|
|
|
|
"name": "create buffer builder",
|
|
|
|
"returns": "buffer builder"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "create command buffer builder",
|
|
|
|
"returns": "command buffer builder"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "create depth stencil state builder",
|
|
|
|
"returns": "depth stencil state builder"
|
|
|
|
},
|
|
|
|
{
|
2018-05-11 17:04:44 +00:00
|
|
|
"name": "create render pass descriptor builder",
|
|
|
|
"returns": "render pass descriptor builder"
|
2017-05-31 00:03:44 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "create input state builder",
|
|
|
|
"returns": "input state builder"
|
|
|
|
},
|
|
|
|
{
|
2017-07-14 14:58:07 +00:00
|
|
|
"name": "create compute pipeline builder",
|
|
|
|
"returns": "compute pipeline builder"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "create render pipeline builder",
|
|
|
|
"returns": "render pipeline builder"
|
2017-05-31 00:03:44 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "create pipeline layout builder",
|
|
|
|
"returns": "pipeline layout builder"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "create queue builder",
|
|
|
|
"returns": "queue builder"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "create sampler builder",
|
|
|
|
"returns": "sampler builder"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "create shader module builder",
|
|
|
|
"returns": "shader module builder"
|
|
|
|
},
|
2017-07-28 01:30:57 +00:00
|
|
|
{
|
|
|
|
"name": "create swap chain builder",
|
|
|
|
"returns": "swap chain builder"
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
{
|
|
|
|
"name": "create texture builder",
|
|
|
|
"returns": "texture builder"
|
|
|
|
},
|
2017-06-14 17:33:45 +00:00
|
|
|
{
|
|
|
|
"name": "tick"
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
{
|
|
|
|
"name": "set error callback",
|
|
|
|
"args": [
|
|
|
|
{"name": "callback", "type": "device error callback"},
|
|
|
|
{"name": "userdata", "type": "callback userdata"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"depth stencil state": {
|
|
|
|
"category": "object"
|
|
|
|
},
|
|
|
|
"depth stencil state builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "depth stencil state"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set depth compare function",
|
|
|
|
"args": [
|
|
|
|
{"name": "depth compare function", "type": "compare function"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
2017-06-01 15:30:03 +00:00
|
|
|
"name": "set depth write enabled",
|
2017-05-31 00:03:44 +00:00
|
|
|
"args" : [
|
2017-06-01 15:30:03 +00:00
|
|
|
{"name": "enabled", "type": "bool"}
|
2017-05-31 00:03:44 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
2017-06-01 15:30:03 +00:00
|
|
|
"name": "set stencil function",
|
2017-05-31 00:03:44 +00:00
|
|
|
"args": [
|
|
|
|
{"name": "face", "type": "face"},
|
2017-06-01 15:30:03 +00:00
|
|
|
{"name": "stencil compare function", "type": "compare function"},
|
2017-05-31 00:03:44 +00:00
|
|
|
{"name": "stencil failure operation", "type": "stencil operation"},
|
|
|
|
{"name": "depth failure operation", "type": "stencil operation"},
|
|
|
|
{"name": "stencil pass operation", "type": "stencil operation"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set stencil mask",
|
|
|
|
"args": [
|
2017-06-02 18:31:53 +00:00
|
|
|
{"name": "readMask", "type": "uint32_t"},
|
|
|
|
{"name": "writeMask", "type": "uint32_t"}
|
2017-05-31 00:03:44 +00:00
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"device error callback": {
|
|
|
|
"category": "natively defined"
|
|
|
|
},
|
|
|
|
"face": {
|
|
|
|
"category": "bitmask",
|
|
|
|
"values": [
|
2017-06-01 15:30:03 +00:00
|
|
|
{"value": 0, "name": "none"},
|
2017-05-31 00:03:44 +00:00
|
|
|
{"value": 1, "name": "back"},
|
|
|
|
{"value": 2, "name": "front"},
|
|
|
|
{"value": 3, "name": "both"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"filter mode": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name":"nearest"},
|
|
|
|
{"value": 1, "name":"linear"}
|
|
|
|
]
|
|
|
|
},
|
2018-03-29 18:02:52 +00:00
|
|
|
"address mode": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name":"repeat"},
|
|
|
|
{"value": 1, "name":"mirrored repeat"},
|
|
|
|
{"value": 2, "name":"clamp to edge"}
|
|
|
|
]
|
|
|
|
},
|
2017-08-01 18:22:52 +00:00
|
|
|
"float": {
|
|
|
|
"category": "native"
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
"index format": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "uint16"},
|
|
|
|
{"value": 1, "name": "uint32"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"input state": {
|
|
|
|
"category": "object"
|
|
|
|
},
|
|
|
|
"input state builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "input state"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set attribute",
|
|
|
|
"args": [
|
|
|
|
{"name": "shader location", "type": "uint32_t"},
|
|
|
|
{"name": "binding slot", "type": "uint32_t"},
|
|
|
|
{"name": "format", "type": "vertex format"},
|
|
|
|
{"name": "offset", "type": "uint32_t"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set input",
|
|
|
|
"args": [
|
|
|
|
{"name": "binding slot", "type": "uint32_t"},
|
|
|
|
{"name": "stride", "type": "uint32_t"},
|
|
|
|
{"name": "step mode", "type": "input step mode"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"input step mode": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "vertex"},
|
|
|
|
{"value": 1, "name": "instance"}
|
|
|
|
]
|
|
|
|
},
|
2017-08-11 21:36:20 +00:00
|
|
|
"load op": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "clear"},
|
|
|
|
{"value": 1, "name": "load"}
|
|
|
|
]
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
"pipeline layout": {
|
|
|
|
"category": "object"
|
|
|
|
},
|
|
|
|
"pipeline layout builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "pipeline layout"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set bind group layout",
|
|
|
|
"args": [
|
|
|
|
{"name": "group index", "type": "uint32_t"},
|
|
|
|
{"name": "layout", "type": "bind group layout"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2017-07-24 17:54:19 +00:00
|
|
|
"primitive topology": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
2017-07-26 22:10:44 +00:00
|
|
|
{"value": 0, "name": "point list"},
|
|
|
|
{"value": 1, "name": "line list"},
|
2017-07-24 17:54:19 +00:00
|
|
|
{"value": 2, "name": "line strip"},
|
2017-07-26 22:10:44 +00:00
|
|
|
{"value": 3, "name": "triangle list"},
|
2017-07-24 17:54:19 +00:00
|
|
|
{"value": 4, "name": "triangle strip"}
|
|
|
|
]
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
"queue": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "submit",
|
|
|
|
"args": [
|
|
|
|
{"name": "num commands", "type": "uint32_t"},
|
|
|
|
{"name": "commands", "type": "command buffer", "annotation": "const*", "length": "num commands"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"queue builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "queue"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2018-05-11 17:04:44 +00:00
|
|
|
"render pass descriptor builder": {
|
2017-05-31 00:03:44 +00:00
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
2018-05-11 17:04:44 +00:00
|
|
|
"returns": "render pass descriptor"
|
2017-05-31 00:03:44 +00:00
|
|
|
},
|
|
|
|
{
|
2018-05-02 22:10:13 +00:00
|
|
|
"name": "set color attachment",
|
2017-05-31 00:03:44 +00:00
|
|
|
"args": [
|
|
|
|
{"name": "attachment slot", "type": "uint32_t"},
|
2018-05-02 22:10:13 +00:00
|
|
|
{"name": "texture view", "type": "texture view"},
|
|
|
|
{"name": "load op", "type": "load op"}
|
2017-05-31 00:03:44 +00:00
|
|
|
]
|
|
|
|
},
|
2017-08-11 21:36:20 +00:00
|
|
|
{
|
2018-05-02 22:10:13 +00:00
|
|
|
"name": "set color attachment clear color",
|
|
|
|
"TODO": "determine where to put these methods (probably BeginRenderPass?)",
|
2017-08-11 21:36:20 +00:00
|
|
|
"args": [
|
|
|
|
{"name": "attachment slot", "type": "uint32_t"},
|
2018-05-02 22:10:13 +00:00
|
|
|
{"name": "clear r", "type": "float"},
|
|
|
|
{"name": "clear g", "type": "float"},
|
|
|
|
{"name": "clear b", "type": "float"},
|
|
|
|
{"name": "clear a", "type": "float"}
|
2017-05-31 00:03:44 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
2018-05-02 22:10:13 +00:00
|
|
|
"name": "set depth stencil attachment",
|
2017-05-31 00:03:44 +00:00
|
|
|
"args": [
|
2018-05-02 22:10:13 +00:00
|
|
|
{"name": "texture view", "type": "texture view"},
|
|
|
|
{"name": "depth load op", "type": "load op"},
|
|
|
|
{"name": "stencil load op", "type": "load op"}
|
2017-05-31 00:03:44 +00:00
|
|
|
]
|
2017-07-17 16:03:16 +00:00
|
|
|
},
|
|
|
|
{
|
2018-05-02 22:10:13 +00:00
|
|
|
"name": "set depth stencil attachment clear value",
|
|
|
|
"TODO": "determine where to put these methods (probably BeginRenderPass?)",
|
2017-07-17 16:03:16 +00:00
|
|
|
"args": [
|
2018-05-02 22:10:13 +00:00
|
|
|
{"name": "clear depth", "type": "float"},
|
|
|
|
{"name": "clear stencil", "type": "uint32_t"}
|
2017-07-17 16:03:16 +00:00
|
|
|
]
|
2017-05-31 00:03:44 +00:00
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2018-05-11 17:04:44 +00:00
|
|
|
"render pass descriptor": {
|
2017-05-31 00:03:44 +00:00
|
|
|
"category": "object"
|
|
|
|
},
|
2017-07-14 14:58:07 +00:00
|
|
|
"render pipeline": {
|
|
|
|
"category": "object"
|
|
|
|
},
|
|
|
|
"render pipeline builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "render pipeline"
|
|
|
|
},
|
2018-05-02 22:10:13 +00:00
|
|
|
{
|
|
|
|
"name": "set color attachment format",
|
|
|
|
"TODO": "Also need sample count",
|
|
|
|
"args": [
|
|
|
|
{"name": "attachment slot", "type": "uint32_t"},
|
|
|
|
{"name": "format", "type": "texture format"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set depth stencil attachment format",
|
|
|
|
"TODO": "Also need sample count",
|
|
|
|
"args": [
|
|
|
|
{"name": "format", "type": "texture format"}
|
|
|
|
]
|
|
|
|
},
|
2017-07-26 20:59:53 +00:00
|
|
|
{
|
|
|
|
"name": "set color attachment blend state",
|
|
|
|
"args": [
|
|
|
|
{"name": "attachment slot", "type": "uint32_t"},
|
|
|
|
{"name": "blend state", "type": "blend state"}
|
|
|
|
]
|
|
|
|
},
|
2017-07-24 17:54:19 +00:00
|
|
|
{
|
|
|
|
"name": "set depth stencil state",
|
|
|
|
"args": [
|
|
|
|
{"name": "depth stencil state", "type": "depth stencil state"}
|
|
|
|
]
|
|
|
|
},
|
2017-09-19 17:38:05 +00:00
|
|
|
{
|
|
|
|
"name": "set index format",
|
|
|
|
"args": [
|
|
|
|
{"name": "format", "type": "index format"}
|
|
|
|
]
|
|
|
|
},
|
2017-07-24 17:54:19 +00:00
|
|
|
{
|
|
|
|
"name": "set input state",
|
|
|
|
"args": [
|
|
|
|
{"name": "input", "type": "input state"}
|
|
|
|
]
|
|
|
|
},
|
2017-07-14 14:58:07 +00:00
|
|
|
{
|
|
|
|
"name": "set layout",
|
|
|
|
"args": [
|
|
|
|
{"name": "layout", "type": "pipeline layout"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
2017-07-24 17:54:19 +00:00
|
|
|
"name": "set primitive topology",
|
2017-07-14 14:58:07 +00:00
|
|
|
"args": [
|
2017-07-24 17:54:19 +00:00
|
|
|
{"name": "primitive topology", "type": "primitive topology"}
|
2017-07-14 14:58:07 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set stage",
|
|
|
|
"args": [
|
|
|
|
{"name": "stage", "type": "shader stage"},
|
|
|
|
{"name": "module", "type": "shader module"},
|
|
|
|
{"name": "entry point", "type": "char", "annotation": "const*", "length": "strlen"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
"sampler": {
|
|
|
|
"category": "object"
|
|
|
|
},
|
|
|
|
"sampler builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "sampler"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set filter mode",
|
|
|
|
"args": [
|
|
|
|
{"name": "mag filter", "type": "filter mode"},
|
|
|
|
{"name": "min filter", "type": "filter mode"},
|
|
|
|
{"name": "mipmap filter", "type": "filter mode"}
|
|
|
|
]
|
2018-03-29 18:02:52 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set address mode",
|
|
|
|
"args": [
|
|
|
|
{"name": "address mode u", "type": "address mode"},
|
|
|
|
{"name": "address mode v", "type": "address mode"},
|
|
|
|
{"name": "address mode w", "type": "address mode"}
|
|
|
|
]
|
2017-05-31 00:03:44 +00:00
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"shader module": {
|
|
|
|
"category": "object"
|
|
|
|
},
|
|
|
|
"shader module builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "shader module"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set source",
|
|
|
|
"args": [
|
|
|
|
{"name": "code size", "type": "uint32_t"},
|
|
|
|
{"name": "code", "type": "uint32_t", "annotation": "const*", "length": "code size"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"shader stage": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "vertex"},
|
|
|
|
{"value": 1, "name": "fragment"},
|
|
|
|
{"value": 2, "name": "compute"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"shader stage bit": {
|
|
|
|
"category": "bitmask",
|
|
|
|
"values": [
|
2017-07-20 15:00:39 +00:00
|
|
|
{"value": 0, "name": "none"},
|
2017-05-31 00:03:44 +00:00
|
|
|
{"value": 1, "name": "vertex"},
|
|
|
|
{"value": 2, "name": "fragment"},
|
|
|
|
{"value": 4, "name": "compute"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"stencil operation": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "keep"},
|
|
|
|
{"value": 1, "name": "zero"},
|
|
|
|
{"value": 2, "name": "replace"},
|
|
|
|
{"value": 3, "name": "invert"},
|
|
|
|
{"value": 4, "name": "increment clamp"},
|
|
|
|
{"value": 5, "name": "decrement clamp"},
|
|
|
|
{"value": 6, "name": "increment wrap"},
|
|
|
|
{"value": 7, "name": "decrement wrap"}
|
2017-06-01 15:30:03 +00:00
|
|
|
]
|
2017-05-31 00:03:44 +00:00
|
|
|
},
|
2017-07-19 22:41:17 +00:00
|
|
|
"swap chain": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "configure",
|
|
|
|
"args": [
|
|
|
|
{"name": "format", "type": "texture format"},
|
2017-08-29 20:35:05 +00:00
|
|
|
{"name": "allowedUsage", "type": "texture usage bit"},
|
2017-07-19 22:41:17 +00:00
|
|
|
{"name": "width", "type": "uint32_t"},
|
|
|
|
{"name": "height", "type": "uint32_t"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "get next texture",
|
|
|
|
"returns": "texture"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "present",
|
|
|
|
"args": [
|
|
|
|
{"name": "texture", "type": "texture"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"swap chain builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "swap chain"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set implementation",
|
|
|
|
"args": [
|
|
|
|
{"name": "implementation", "type": "uint64_t"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
"texture": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "create texture view builder",
|
|
|
|
"returns": "texture view builder"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "transition usage",
|
|
|
|
"args": [
|
|
|
|
{"name": "usage", "type": "texture usage bit"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "freeze usage",
|
|
|
|
"args": [
|
|
|
|
{"name": "usage", "type": "texture usage bit"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"texture builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "texture"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set dimension",
|
|
|
|
"args": [
|
|
|
|
{"name": "dimension", "type": "texture dimension"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set extent",
|
|
|
|
"args": [
|
|
|
|
{"name": "width", "type": "uint32_t"},
|
|
|
|
{"name": "height", "type": "uint32_t"},
|
|
|
|
{"name": "depth", "type": "uint32_t"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set format",
|
|
|
|
"args": [
|
|
|
|
{"name": "format", "type": "texture format"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set mip levels",
|
|
|
|
"args": [
|
|
|
|
{"name": "num mip levels", "type": "uint32_t"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set allowed usage",
|
|
|
|
"args": [
|
|
|
|
{"name": "usage", "type": "texture usage bit"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "set initial usage",
|
|
|
|
"args": [
|
|
|
|
{"name": "usage", "type": "texture usage bit"}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"texture dimension": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "2D"}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"texture usage bit": {
|
|
|
|
"category": "bitmask",
|
|
|
|
"values": [
|
|
|
|
{"value": 0, "name": "none"},
|
|
|
|
{"value": 1, "name": "transfer src"},
|
|
|
|
{"value": 2, "name": "transfer dst"},
|
|
|
|
{"value": 4, "name": "sampled"},
|
|
|
|
{"value": 8, "name": "storage"},
|
2017-07-19 22:41:17 +00:00
|
|
|
{"value": 16, "name": "output attachment"},
|
|
|
|
{"value": 32, "name": "present"}
|
2017-05-31 00:03:44 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
"texture view": {
|
|
|
|
"category": "object"
|
|
|
|
},
|
|
|
|
"texture view builder": {
|
|
|
|
"category": "object",
|
|
|
|
"methods": [
|
|
|
|
{
|
|
|
|
"name": "get result",
|
|
|
|
"returns": "texture view"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"texture format": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
2017-07-17 16:03:16 +00:00
|
|
|
{"value": 0, "name": "r8 g8 b8 a8 unorm"},
|
2018-01-22 19:09:08 +00:00
|
|
|
{"value": 1, "name": "r8 g8 unorm"},
|
|
|
|
{"value": 2, "name": "r8 unorm"},
|
|
|
|
{"value": 3, "name": "r8 g8 b8 a8 uint"},
|
|
|
|
{"value": 4, "name": "r8 g8 uint"},
|
|
|
|
{"value": 5, "name": "r8 uint"},
|
|
|
|
{"value": 6, "name": "b8 g8 r8 a8 unorm"},
|
|
|
|
{"value": 7, "name": "d32 float s8 uint"}
|
2017-05-31 00:03:44 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
"vertex format": {
|
|
|
|
"category": "enum",
|
|
|
|
"values": [
|
2018-04-10 18:35:17 +00:00
|
|
|
{"value": 0, "name": "float r32 g32 b32 a32"},
|
|
|
|
{"value": 1, "name": "float r32 g32 b32"},
|
|
|
|
{"value": 2, "name": "float r32 g32"},
|
|
|
|
{"value": 3, "name": "float r32"},
|
|
|
|
{"value": 4, "name": "int r32 g32 b32 a32"},
|
|
|
|
{"value": 5, "name": "int r32 g32 b32"},
|
|
|
|
{"value": 6, "name": "int r32 g32"},
|
|
|
|
{"value": 7, "name": "int r32"},
|
|
|
|
{"value": 8, "name": "ushort r16 g16 b16 a16"},
|
|
|
|
{"value": 9, "name": "ushort r16 g16"},
|
|
|
|
{"value": 10, "name": "unorm r8 g8 b8 a8"},
|
|
|
|
{"value": 11, "name": "unorm r8 g8"}
|
2017-05-31 00:03:44 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
"void": {
|
|
|
|
"category": "native"
|
|
|
|
},
|
2018-02-04 16:07:02 +00:00
|
|
|
"uint8_t": {
|
|
|
|
"category": "native"
|
|
|
|
},
|
2017-05-31 00:03:44 +00:00
|
|
|
"uint32_t": {
|
|
|
|
"category": "native"
|
2017-07-19 22:41:17 +00:00
|
|
|
},
|
|
|
|
"uint64_t": {
|
|
|
|
"category": "native"
|
2017-05-31 00:03:44 +00:00
|
|
|
}
|
|
|
|
}
|