diff --git a/documents/Specification/MaterialX.PBRSpec.md b/documents/Specification/MaterialX.PBRSpec.md index d748dabb96..a7924a675e 100644 --- a/documents/Specification/MaterialX.PBRSpec.md +++ b/documents/Specification/MaterialX.PBRSpec.md @@ -114,7 +114,7 @@ In order to simplify authoring of complex materials, our model supports the noti ### Bump and Normal Mapping -The surface normal used for shading calculations is supplied as input to each BSDF that requires it. The normal can be perturbed by bump or normal mapping, before it is given to the BSDF. As a result, one can supply different normals for different BSDFs for the same shading point. When layering BSDFs, each layer can use different bump and normal maps. +The surface normal used for shading calculations is supplied as input to each BSDF that requires it. The normal can be perturbed by bump or normal mapping, before it is given to the BSDF. As a result, one can supply different normals for different BSDFs for the same shading point. When layering BSDFs, each layer can use different bump and normal maps. Normals, tangents, and bitangents used for bump or normal mapping are expected to be normalized. ## Volumes diff --git a/documents/Specification/MaterialX.Proposals.md b/documents/Specification/MaterialX.Proposals.md index 6c81f19d4b..32546d03b8 100644 --- a/documents/Specification/MaterialX.Proposals.md +++ b/documents/Specification/MaterialX.Proposals.md @@ -5,7 +5,7 @@ MaterialX Proposals v1.39 # MaterialX: Proposed Additions and Changes -**Proposals for Version 1.39** +**Proposals for Version 1.39** September 15, 2024 @@ -19,17 +19,17 @@ As such, those forward-looking proposals have been moved from the formal Specifi ## Table of Contents -**[Introduction](#introduction)** +**[Introduction](#introduction)** -**[Proposals: General](#propose-general)** +**[Proposals: General](#propose-general)** -**[Proposals: Elements](#propose-elements)** +**[Proposals: Elements](#propose-elements)** -**[Proposals: Stdlib Nodes](#propose-stdlib-nodes)** +**[Proposals: Stdlib Nodes](#propose-stdlib-nodes)** -**[Proposals: PBR Nodes](#propose-pbr-nodes)** +**[Proposals: PBR Nodes](#propose-pbr-nodes)** -**[Proposals: NPR Nodes](#propose-npr-nodes)** +**[Proposals: NPR Nodes](#propose-npr-nodes)**
@@ -393,6 +393,16 @@ Output the RGB and alpha channels of a color4 as separate outputs. # Proposals: PBR Nodes +### Unit-Length Normal and Tangent-Frame Inputs + +Normals, tangents, bitangent inputs should be unit-length direction vectors +in the given coordinate space. This follows from the existing math used by BSDFs +and EDFs: +- where the dot products with a normal are used a cosines. +- microfacet distributions construct local frames from the vectors. +- sampling PDFs are defined over unit (hemi)spheres. + +Non-unit normals could then change energy, sampling density, reflected/transmitted directions. The alternative is to define that they do not have to be unit length, and then amend the GLSL implementations to handle this.
diff --git a/resources/Materials/TestSuite/libraries/metal/libraries/metal_definition.mtlx b/resources/Materials/TestSuite/libraries/metal/libraries/metal_definition.mtlx
index b95bff5148..492beb9659 100644
--- a/resources/Materials/TestSuite/libraries/metal/libraries/metal_definition.mtlx
+++ b/resources/Materials/TestSuite/libraries/metal/libraries/metal_definition.mtlx
@@ -6,7 +6,7 @@
-
+
@@ -33,7 +33,7 @@
-
+
diff --git a/resources/Materials/TestSuite/locale/numericformat.mtlx b/resources/Materials/TestSuite/locale/numericformat.mtlx
index e9aa3603ce..db038d104c 100644
--- a/resources/Materials/TestSuite/locale/numericformat.mtlx
+++ b/resources/Materials/TestSuite/locale/numericformat.mtlx
@@ -3,7 +3,7 @@