Select to view content in your preferred language

USD user created attribute doesn't get exported

371
2
04-26-2023 11:58 AM
GunSikKim
New Contributor

Hi,

I'm having issue with USD export,

if there's user created attribute and connected to any MAP layer, USD still have those attr

but if any attributes, value has been set in CGA file and "not customized" (changing values manually)

attributes doesn't show up in USD files

This is a big problem and limits USD workflow big time

Could you guys please look into it?

 

GunSikKim_0-1682535336332.png

for example, all the attr connected to map gets pass along,
but all those default numbers set in CGA file, if I don't change it manually (so it's hard-coded),
USD doesn't attach those attributes
both str and int value

Thank you

0 Kudos
2 Replies
SimonHaegler
Esri Contributor

Thanks for your feedback - I'll have a look and get back to you asap.

0 Kudos
SimonHaegler
Esri Contributor

The current behavior of not exporting default CGA attribute values is expected. In general, the concept of "default" value is not so clear, as you can see in below example where attr b = a + 5, i.e. is the default value for b = 8 or 6?

What is your use case for these rule attributes in USD?

An alternative might be for you to use the "report" statement which will be exported as USD attributes on the USD "component" nodes. This allows you to control the semantics of values independently:
SimonHaegler_0-1683102207076.png

The reported value will appear prefixed with the "CityEngine:Reports:" namespace on the "component" node:

SimonHaegler_1-1683102673981.png

Another reason we only export non-default values of CGA rule attributes is motivated by use cases which need to replicate the input to the model generation, e.g. in Palladio (Houdini plugin). One would export the shapes (not the models) with the rule attribute values. In this use case, setting attributes to default values would be wrong as illustrated in the above example (b would be fixed to 8 and not generated as 6 if a is 3).

 

0 Kudos