Instanceable prims and visibility

Hello !

I am currently working on usd instances and I am facing an issue when changing the visibility of instanceable prims that contain PointInstancers in their sub hierarchy specifically.
Let’s say I have an asset with its geometry containing meshes and a PointInstancer (like a tree, with instantiated leaves). Now, I want to build an assembly with it. I create a new stage with some Xform prims referencing the tree, instanceable set to true and with transforms applied. I can save this stage into its own usd file, open it in usdView or other DCCs and hide any instance without any problem.

The actual issue appears when the assembly is referenced elsewhere, in a shot breakdown for example. At this point, when I open the shot breakdown stage, I am still able to hide the instances in the assembly but there will always be one (usually the first instance) that will hide the PointInstancer for every other instances. The condition for all the PointInstancers to reappear can vary depending on the software used to open the stage:

  • In Houdini, if the hidden instance is set back to visible, all the PointInstancers are drawn again. Everytime you hide the ‘problematic’ instance all the PointInstancers disappear again:

  • In Maya or usdview, you’ll need to set the instance back to visible and hide another one to make the PointInstancers reappear.

In the last scenario, the issue seems to be fixed until the stage is reloaded.

I know the stage uses the one of the instanceable prim of a same group as the source to create a prototype which will be shared by all the instanceable prims with the same arcs. Could edits on this selected instance change the prototype and therefore other instances ?

I also noticed that setting instanceable to false and back to true on all instances right after i opened the breakdown fixes the issue. If I am right, those edits are added to the session layer which is created when the stage is opened.

I made a simple package for anyone who would like to reproduce the issue. You will find the asset.usda file which describe an asset with a cube (in blue) and smaller cubes instantiated using a PointInstancer (in green). The instances.usda builds the assembly, creating three instances of the asset. Finally, breakdown.usda references instances.usda as it would be done to bring the assembly in higher levels of hierarchy like in a shot. (2.5 KB)

Hi @paulf , lovely description of the behavior, which is most definitely a bug in the imaging system. Would you be willing to create a gitHub Issue with your materials, repro steps, and which version of OpenUSD you are seeing it with?

Thank you!