Skip to content

Conversation

@jstone-lucasfilm
Copy link
Member

@jstone-lucasfilm jstone-lucasfilm commented Dec 16, 2025

Building upon the work in the new comparenodedefs.py script, this changelist makes several improvements to the tables in the StandardNodes specification, bringing the specification into closer alignment with the data libraries.

Using the output of comparenodedefs.py as a measure, this changelist reduces the number of differences between the StandardNodes specification and data libraries from 122 to 46.

Additionally, this changelist enables GitHub CI for changelists containing only edits to Markdown files, so that comparenodedefs.py is run on changes that contain only specification updates.

Building upon the work in the new `comparenodes.py` script, this changelist makes several improvements to the tables in the StandardNodes specification, bringing the specification into closer alignment with the data libraries.

Using the output of `comparenodes.py` as a measure, this changelist reduces the number of differences between the StandardNodes specification and data libraries from 122 to 46.

Additionally, this changelist enables GitHub CI for changelists containing only edits to Markdown files, so that `comparenodes.py` is run on changes that contain only specification updates.
@jstone-lucasfilm
Copy link
Member Author

For reference, here is the new output of comparenodedefs.py, when run on the specification and data libraries in this changelist:

Comparing:
  Specification: /home/runner/work/MaterialX/MaterialX/documents/Specification/MaterialX.StandardNodes.md
  Data Library: /home/runner/work/MaterialX/MaterialX/libraries/stdlib/stdlib_defs.mtlx

Parsing specification...
  Found 140 nodes with 659 node signatures
Loading data library...
  Found 143 nodes with 689 node signatures

Comparing node signatures...

======================================================================
COMPARISON RESULTS: 46 difference(s) found
======================================================================

Nodes in Specification but not Data Library (1):
--------------------------------------------------
  displacement

Nodes in Data Library but not Specification (4):
--------------------------------------------------
  ramp
  ramp_gradient
  surfacematerial
  volumematerial

Nodes with Different Input Sets (13):
--------------------------------------------------
  dot: (in:boolean) -> out:boolean
    Extra in library: note:string
  dot: (in:color3) -> out:color3
    Extra in library: note:string
  dot: (in:color4) -> out:color4
    Extra in library: note:string
  dot: (in:filename) -> out:filename
    Extra in library: note:string
  dot: (in:float) -> out:float
    Extra in library: note:string
  dot: (in:integer) -> out:integer
    Extra in library: note:string
  dot: (in:matrix33) -> out:matrix33
    Extra in library: note:string
  dot: (in:matrix44) -> out:matrix44
    Extra in library: note:string
  dot: (in:string) -> out:string
    Extra in library: note:string
  dot: (in:vector2) -> out:vector2
    Extra in library: note:string
  dot: (in:vector3) -> out:vector3
    Extra in library: note:string
  dot: (in:vector4) -> out:vector4
    Extra in library: note:string
  time: () -> out:float
    Extra in library: fps:float

Node Signatures in Data Library but not Specification (28):
--------------------------------------------------
  convert: (in:boolean) -> out:surfaceshader
  convert: (in:color3) -> out:surfaceshader
  convert: (in:color4) -> out:surfaceshader
  convert: (in:float) -> out:surfaceshader
  convert: (in:integer) -> out:surfaceshader
  convert: (in:vector2) -> out:surfaceshader
  convert: (in:vector3) -> out:surfaceshader
  convert: (in:vector4) -> out:surfaceshader
  dot: (in:displacementshader, note:string) -> out:displacementshader
  dot: (in:lightshader, note:string) -> out:lightshader
  dot: (in:surfaceshader, note:string) -> out:surfaceshader
  dot: (in:volumeshader, note:string) -> out:volumeshader
  fractal2d: (amplitude:float, octaves:integer, lacunarity:float, diminish:float, texcoord:vector2) -> out:color3
  fractal2d: (amplitude:float, octaves:integer, lacunarity:float, diminish:float, texcoord:vector2) -> out:color4
  fractal2d: (amplitude:vector3, octaves:integer, lacunarity:float, diminish:float, texcoord:vector2) -> out:color3
  fractal2d: (amplitude:vector4, octaves:integer, lacunarity:float, diminish:float, texcoord:vector2) -> out:color4
  fractal3d: (amplitude:float, octaves:integer, lacunarity:float, diminish:float, position:vector3) -> out:color3
  fractal3d: (amplitude:float, octaves:integer, lacunarity:float, diminish:float, position:vector3) -> out:color4
  fractal3d: (amplitude:vector3, octaves:integer, lacunarity:float, diminish:float, position:vector3) -> out:color3
  fractal3d: (amplitude:vector4, octaves:integer, lacunarity:float, diminish:float, position:vector3) -> out:color4
  noise2d: (amplitude:float, pivot:float, texcoord:vector2) -> out:color3
  noise2d: (amplitude:float, pivot:float, texcoord:vector2) -> out:color4
  noise2d: (amplitude:vector3, pivot:float, texcoord:vector2) -> out:color3
  noise2d: (amplitude:vector4, pivot:float, texcoord:vector2) -> out:color4
  noise3d: (amplitude:float, pivot:float, position:vector3) -> out:color3
  noise3d: (amplitude:float, pivot:float, position:vector3) -> out:color4
  noise3d: (amplitude:vector3, pivot:float, position:vector3) -> out:color3
  noise3d: (amplitude:vector4, pivot:float, position:vector3) -> out:color4

|`falloff` |Falloff width used to blend neighboring tiles at their edges; larger values produce smoother blends|float |0.5 |
|`falloffcontrast` |Contrast applied to the falloff blending to sharpen (values >1) or soften (values <1) transitions |float |0.5 |
|`lumacoeffs` |The luma coefficients of the current working color space |color3 |0.2722287, 0.6740818, 0.0536895|
|`out` |Output: the sampled texture value |Same as `default`|__zero__ |
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nitpick: For consistency with the other nodes would it make sense to have the output define the data type, and let default derive from this? That is, just flip the relation here so default says Same as 'out'

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea, and I've made this change across the texture nodes for consistency.

Copy link
Contributor

@niklasharrysson niklasharrysson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me, and I only had a minor comment above.

@jstone-lucasfilm jstone-lucasfilm merged commit d6ecee3 into AcademySoftwareFoundation:main Dec 17, 2025
33 checks passed
@jstone-lucasfilm jstone-lucasfilm deleted the dev_improve_tables branch December 17, 2025 16:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants