Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EMSUSD-1626 : Support MaterialX document in USD Exporter #4107

Merged
merged 7 commits into from
Feb 25, 2025

Conversation

derlerk
Copy link
Collaborator

@derlerk derlerk commented Feb 6, 2025

ShaderWriter for the LookdevX MaterialXStack material.
Test that validate an export of MaterialXStack with surfaceshader and displacement

Test that validate an export of MaterialXStack with surfaceshader and displacement
@derlerk derlerk self-assigned this Feb 6, 2025
@derlerk derlerk assigned derlerk and unassigned derlerk Feb 7, 2025
@derlerk derlerk assigned derlerk and unassigned derlerk Feb 10, 2025
@derlerk derlerk assigned derlerk and unassigned derlerk Feb 10, 2025
@derlerk derlerk assigned derlerk and unassigned derlerk Feb 10, 2025
@derlerk derlerk marked this pull request as ready for review February 11, 2025 15:19
Copy link
Collaborator

@JGamache-autodesk JGamache-autodesk left a comment

Choose a reason for hiding this comment

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

Very good. I would say 99% done. Sadly there are a few corner cases in MaterialX that need to be handled correctly. I have described the ones I encountered in the past.

@JGamache-autodesk
Copy link
Collaborator

Sorry about that, but I remembered another corner case that will hit us at some point. Simplest form is:
image
You need to handle shared_image1 correctly if exporting both surfacematerials. I suspect a first implementation will split it and create one image node per material. Maybe later we can consider using USD referencing to keep it shared.

@derlerk
Copy link
Collaborator Author

derlerk commented Feb 21, 2025

Sorry about that, but I remembered another corner case that will hit us at some point. Simplest form is: image You need to handle shared_image1 correctly if exporting both surfacematerials. I suspect a first implementation will split it and create one image node per material. Maybe later we can consider using USD referencing to keep it shared.

This use case is already working, but indeed it is duplicating the image node. We could in the future come up with a way of referencing it to avoid duplication.

Generalize output name handling to accomodate the special cases.
Handle more input meta data.
Add test case for artistic_ior (multi output node)
Rework test structure to use mtlx files instead of a maya file.
Copy link
Collaborator

@JGamache-autodesk JGamache-autodesk left a comment

Choose a reason for hiding this comment

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

Thanks for doing the work! Looks good to me now.

@derlerk derlerk assigned derlerk and unassigned derlerk Feb 24, 2025
@derlerk derlerk added the ready-for-merge Development process is finished, PR is ready for merge label Feb 25, 2025
@seando-adsk seando-adsk added the import-export Related to Import and/or Export label Feb 25, 2025
@seando-adsk seando-adsk merged commit ff3bfd9 into dev Feb 25, 2025
11 checks passed
@seando-adsk seando-adsk deleted the derlerk/EMSUSD-1626/MaterialXStackShaderWriter branch February 25, 2025 19:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
import-export Related to Import and/or Export ready-for-merge Development process is finished, PR is ready for merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants