Skip to content

Conversation

JoshuaSenouf
Copy link
Collaborator

It will build a new executable, MaterialXGenOslNodes_LibsToOso, inside the bin install directory in your install location.
Both the naming of the tool and its install location are likely going to change, obviously.

It can be used like so:

MaterialXGenOslNodes_LibsToOso --outputPath /path/to/my/output/dir --oslCompilerPath /path/to/my/oslc --oslIncludePath /path/to/my/osl/include

This alone will codegen and compile all the MaterialX NodeDef with a valid OSL implementation found in all the libraries in the provided output directory.

The --outputPath, --oslCompilerPath and --oslIncludePath arguments are all mandatory for the tool to work, and they will be checked for both presence and validity (to a degree).

It is also possible to specify a couple of optional arguments, such as:

  • --libraries, that allows to specify the comma separated MaterialX libraries we want to process instead of everything, such as stdlib,pbrlib.
  • --prefix, that allows adding a prefix to both the filename of a shader, as well as the shader function itself in OSL.

@JoshuaSenouf JoshuaSenouf self-assigned this Sep 26, 2025
Copy link

@ld-kerley ld-kerley left a comment

Choose a reason for hiding this comment

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

Looks pretty good to me - I think ChrisH will want to drop his shader generator in to the same source/MaterialXGenOslNodes module - and bundle the tool and the new generator together.

@JoshuaSenouf JoshuaSenouf force-pushed the libraries-to-oso-tool branch 3 times, most recently from ef932cd to f3c3cbc Compare September 29, 2025 00:49
@JoshuaSenouf JoshuaSenouf marked this pull request as ready for review September 29, 2025 00:50
@JoshuaSenouf JoshuaSenouf removed their assignment Sep 29, 2025
…codegen and compile MaterialX libraries, as part as the ongoing work towards a new shader generator, "MaterialXGenOslNodes".
…th", with the latter being optional, so we can split where we are codegening and compiling our shaders.
@JoshuaSenouf JoshuaSenouf force-pushed the libraries-to-oso-tool branch from ba0e932 to a37b8cf Compare October 3, 2025 20:55
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