You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: extensions/2.0/Khronos/KHR_texture_procedurals/README.md
+26-23Lines changed: 26 additions & 23 deletions
Original file line number
Diff line number
Diff line change
@@ -57,7 +57,7 @@ Textures represented as procedural graphs provides a way to extend the capabilit
57
57
58
58
For the first version of this extension nodes which are used to define shading models are not allowed. Please refer to the [resources](#resources) section for links to supported MaterialX node definitions.
59
59
60
-
2.**Fidelity**: Provide the ability to generate complex patterns, noise, or other effects that currently must be "baked" into texture maps. Provide the ability to provide mappings from one shading model to another without baking in a consistent manner via procedural graphs. Provide the ability to support NPR effects for unlit materials. Reduces runtime memory usage by generating patterns / shading programmatically.
60
+
2.**Fidelity**: Provide the ability to generate complex patterns, noise, or other effects that currently must be "baked" into texture maps. Provide the ability to provide mappings from one shading model to another without baking in a consistent manner via procedural graphs. Provide the ability to map procedurals graphs to unlit materials. Reduces runtime memory usage by generating patterns / shading programmatically.
61
61
62
62
3.**Editability and Extensibility**: Extend runtime editability by exposing logic and interfaces for procedural graphs as well as providing a means to create new or extend existing node definitions.
63
63
@@ -93,7 +93,7 @@ The following is a set of definitions using MaterialX nomenclature to provide co
93
93
94
94
## Extension Declaration
95
95
96
-
Usage is indicated by adding the `KHR_texture_procedurals` extension identifier to the `extensionsUsed` array.
96
+
Usage of the procedural structure is indicated by adding the `KHR_texture_procedurals` extension identifier to the `extensionsUsed` array.
97
97
98
98
```json
99
99
{
@@ -102,36 +102,39 @@ Usage is indicated by adding the `KHR_texture_procedurals` extension identifier
102
102
]
103
103
}
104
104
```
105
-
with the extension object defined in the `extensions array:
105
+
To indicate the usage of a specific set of definitions an additional entry must be added to `extensionsUsd`. For example usage of definitions from a version of the MaterialX would look like this:
106
+
```json
107
+
{
108
+
"extensionsUsed": [
109
+
"KHR_texture_procedurals"
110
+
"KHR_texture_procedurals_MaterialX_<version>"
111
+
]
112
+
}
113
+
```
114
+
where `<version>` is specified as a string in the form of `<major version>.<minor version>`. For example, if the MaterialX library version is 1.39, the extension string would be: `KHR_texture_procedurals_MaterialX_1.39`.
106
115
116
+
Note that two versions of the same library **cannot** be used in the same glTF asset. For example the following is considered to be invalid:
117
+
```json
118
+
{
119
+
"extensionsUsed": [
120
+
"KHR_texture_procedurals"
121
+
"KHR_texture_procedurals_MaterialX_1.39"
122
+
"KHR_texture_procedurals_MaterialX_2.0>"
123
+
]
124
+
}
125
+
```
126
+
127
+
Usage of a given extension is defined in the `extensions` object as follows:
It is assumed that a mimetype is always required. As part of the mimetype a version `<MaterialX_version>` is specified. This is the version of the MaterialX library specification used when writing to glTF. The version is specified as a string in the form of `<major version>.<minor version>`. For example, if the MaterialX library version is 1.39, the mimetype would be `application/mtlx+json;version=1.39`.
118
-
119
-
The correspond version is specified in a MaterialX XML document as follows:
120
-
121
-
```xml
122
-
<materialxversion="1.39">
123
-
</materialx>
124
-
```
125
-
126
-
The version in the mimetype __is not__ the extension version. If in the future the schema needs to be modified (perhaps due to changes in MaterialX) then a new extension version would be required.
127
-
128
-
The `procedurals` array specifies the procedural graphs that are used in the glTF asset.
129
-
130
-
### Versioning
131
-
132
-
Elements from different versions of MaterialX is disallowed. External tooling must handle this (e.g. by performing an "upgrade" operation).
0 commit comments