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: bug switching sub-assembly representation from Full to Collapsed #62

Closed
chadrik opened this issue Sep 20, 2016 · 4 comments
Closed

Comments

@chadrik
Copy link
Contributor

chadrik commented Sep 20, 2016

To create the assets used in the repro below, I first completed the endToEnd tutorial through the creation of Room_set.usd

To reproduce:

Create an assembly, set the it to Expanded, and set one of the children to Full:

import maya.cmds as cmds
root = cmds.assembly(name='testAss', type='pxrUsdReferenceAssembly')
cmds.setAttr(root + '.filePath', '/Volumes/sv-dev01/devRepo/chad/projects/usd/tutorials/endToEnd/models/Room_set/Room_set.usd', type='string')
cmds.assembly(root, active='Expanded', edit=True)
sub = 'NS_testAss:Ball_1'
cmds.assembly(sub, active='Full', edit=True)

Now set the child to Collapsed:

cmds.assembly(sub, active='Collapsed', edit=True)

What we should see is the Ball asset as a proxy, instead we see the entire Room_set, offset by the ball's xform.

@jtran56
Copy link

jtran56 commented Sep 22, 2016

Filed as internal issue #137727.

@chadrik
Copy link
Contributor Author

chadrik commented Sep 22, 2016

I just checked and the solution from issue #61 of setting the root primPath work here as well:

import maya.cmds as cmds
root = cmds.assembly(name='testAss', type='pxrUsdReferenceAssembly')
cmds.setAttr(root + '.filePath', '/projects/usd/tutorials/endToEnd/models/Room_set/Room_set.usd', type='string')
# Must set primPath!
cmds.setAttr(root + '.primPath', '/Room_set', type='string')
cmds.assembly(root, active='Expanded', edit=True)
sub = 'NS_testAss:Ball_1'
cmds.assembly(sub, active='Full', edit=True)

I think both of these issues are now a question of how best to prevent users from making this mistake. Some options:

  • finish the "Create -> Scene Assembly" menu in Maya and enforce the automatic setting of primPath there. Right now all it does is make the assembly node with no attributes set.
  • add an explanation of the modes and how to setup the assembly node to the docs
  • change the behavior: It's somewhat inconvenient to have to manually set the primPath to the defaultPrim, and it's not intuitive that not setting it would invoke an alternate mode which breaks nested assemblies. So from my limited point-of-view it would be good to have the default behavior (omitting the primPath) be one that works, while having the alternate mode be something that is more explicitly enabled. but like I said, I'm not sure what the purpose of the alternate mode is, so that may be a misguided suggestion.

@spiffmon
Copy link
Member

Hey @chadrik - we think the work by @mattyjams to make nested assemblies pull from the main stage also addressed this (we can no longer repro)... and you're also no longer interested in assemblies :-) Closing!

@chadrik
Copy link
Contributor Author

chadrik commented Jan 20, 2017

roger. you can probably close #61 too

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

No branches or pull requests

3 participants