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

Maya: USD workflow with maya usd #334

Closed
wants to merge 15 commits into from

Conversation

BigRoy
Copy link
Collaborator

@BigRoy BigRoy commented Mar 29, 2024

Changelog Description

Implement more of Maya USD workflows:

  • Add more options to the Maya USD Extractor
  • Export a layer of a Maya USD proxy, e.g. lookdev done with Maya's lookdevx.
  • Prototype loading of USD references into a Maya USD proxy while keeping it managed by the pipeline
  • Prototype loading of Maya references into a Maya USD proxy while keeping it managed by the pipeline

Additional info

Some of the logic here has been used in our production - but there's also quite a bit that we didn't use at all in the actual production. The logic here can thus be considered mostly a prototype and up for discussion.

We mostly used the loading of USD files to a proxy - for previewing purposes. And the Maya USD export from Maya.

I also had this prototype to export native maya model + lookdev done with arnold to just a "look" layer override for a USD stage. (So basically a look export without the geometry present so that you could overlay it over the asset; however we did not use that.)

Anyway, input is more than welcome!

This is basically the Maya part of this equivalent OpenPype PR ynput/OpenPype#5925 but with some more improvements we did while using some parts in production.

Testing notes:

  1. For now, play around with the features! (Until PR is ready and out of draft!)

@ynbot ynbot added size/M type: enhancement Improvement of existing functionality or minor addition host: Maya labels Mar 29, 2024
@MustafaJafar MustafaJafar added community Issues and PRs coming from the community members USD Any USD related PR or issue labels Apr 1, 2024
BigRoy and others added 13 commits April 5, 2024 12:00
…a_reference.py

Co-authored-by: Kayla Man <64118225+moonyuet@users.noreply.github.com>
…ancement/maya_usd

# Conflicts:
#	server_addon/maya/server/settings/publishers.py
…ublishing would create runtime USD instances that do not have creator attributes data.
…ancement/maya_usd

# Conflicts:
#	server_addon/maya/client/ayon_maya/api/usdlib.py
#	server_addon/maya/client/ayon_maya/plugins/create/create_maya_usd_layer.py
#	server_addon/maya/client/ayon_maya/plugins/load/load_maya_usd_add_maya_reference.py
#	server_addon/maya/client/ayon_maya/plugins/load/load_maya_usd_add_reference.py
#	server_addon/maya/client/ayon_maya/plugins/publish/extract_maya_usd.py
#	server_addon/maya/client/ayon_maya/plugins/publish/extract_maya_usd_layer.py
@antirotor
Copy link
Member

So I've been playing with it. Found particular case I don't know how we should handle. I was trying to reference shot USD consisting of just sublayers:

#usda 1.0
(
    framesPerSecond = 25
    metersPerUnit = 1
    subLayers = [
        @...:SDF_FORMAT_ARGS:layer_id=lighting&order=600@,
        @...:SDF_FORMAT_ARGS:layer_id=animation&order=300@,
        @...:SDF_FORMAT_ARGS:layer_id=layout&order=200@,
        @...:SDF_FORMAT_ARGS:layer_id=model&order=100@
    ]
    timeCodesPerSecond = 25
    upAxis = "Y"
)

Loader gave me:

Warning: In </root>: Unresolved reference prim path @...@<defaultPrim> introduced by @anon:00000116D1C58160:anonymousLayer1@</root>

and nothing was referenced (so it is more error than warning). When trying to do it manually the error is more clear:

Warning: The file [...usd] does not contain a default prim, the reference will be invalid

Which make sense.It basically means we can reference in only USD with defined defaultPrim. In this case, how to handle it? With different family? Just failing during the load?

@BigRoy
Copy link
Collaborator Author

BigRoy commented Jun 18, 2024

So I've been playing with it. Found particular case I don't know how we should handle. I was trying to reference shot USD consisting of just sublayers...

@antirotor Could you elaborate a bit more on how to reproduce this particular behavior?

I suppose you were just publishing some "shot contributions" using Maya USD similar to this:
image

Or could you share your instance publish settings that produced these shot USD files?

@iLLiCiTiT
Copy link
Member

Please move to https://github.com/ynput/ayon-maya if is still relevant.

@iLLiCiTiT iLLiCiTiT closed this Jul 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
community Issues and PRs coming from the community members host: Maya size/M type: enhancement Improvement of existing functionality or minor addition USD Any USD related PR or issue
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants