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

katana PxrUsdIn doesn't respect custom attrs #45

Closed
BSalem opened this issue Sep 3, 2016 · 4 comments
Closed

katana PxrUsdIn doesn't respect custom attrs #45

BSalem opened this issue Sep 3, 2016 · 4 comments

Comments

@BSalem
Copy link

BSalem commented Sep 3, 2016

writing usd with custom attribute on objects using USD_UserExportedAttributesJson attribute, then reading this usd in Katana, then the custom attrs are not read and not available for Katana except if the attributes were written in the "primvars:" namespace.

I expected writing some static/constant attrs out as material tags and texture tags that don't need to be in primitive scope and doesn't need interpolation.

@spiffmon
Copy link
Member

spiffmon commented Sep 4, 2016

Hi Belal,
pxrUsdIn will imort any usd attributes in the property namespace "userProperties", placing them in a compound of the same name on the katana location. SO, for example, if your prim in USD has:

def Sphere "MyBall"
{
string userProperties:myAttr = "boo!"
}

then pxrUsdIn should import it onto /World/MyBall.userProperties.myAttr

Apologies about the lack of documentation on this, and lack of official API in USD core for authoring these (and the confusing "custom" metadata on USD properties, which we plan to deprecate).

Let me know if you have further problems here!

--spiff

@BSalem
Copy link
Author

BSalem commented Sep 5, 2016

Hi Sebastian,
Thanks for the info.. Yeah, I understand that the documentation cannot be as accurate and covering everything at this stage.
I tried the 'userProperties' namesapce, this works for me.
But I vote for two things regarding to custom attrs workflow, both are based on giving the user the freedom to do with them whatever he wants and to put them where ever he wants to satisfy any unknown/custom needs that somebody may need in the future):

  1. In Katana.. all custom attrs to be read and created into the same namespace like how they came in the usd no matter what the namespace was, and if no namespace, it can just be on the location root (like myBall.visibile) (just as the user wanted).
  2. In Maya.. as it wrote the custom attrs, it need to be able to create them when importing a USD with custom attrs. (it's OK if all the attributes list will be created under either the shape or the transform node in maya when importing the USD, but it would be awesome if they are available back into maya).

@BSalem BSalem closed this as completed Sep 5, 2016
@spiffmon
Copy link
Member

spiffmon commented Sep 5, 2016

  1. Another not-yet-documented feature: pxrUsdIn has a string-array parameter 'extraAttributesOrNamespaces', which you can populate with attribute prefixes/namespaces that katana will search for on each UsdPrim. We do not want to blindly suck in all data on prims, as there are scenarios in which this will overwhelm katana, and we want to be as memory efficient as possible.
  2. Absolutely! It's on the big 'to do' list :-)

@BSalem
Copy link
Author

BSalem commented Sep 6, 2016

Sounds wonderful.. thanks for the clarification.

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

2 participants