OpenUSD
OpenUSD copied to clipboard
UsdGeomPoints should have InvisibleID Attr
Description of Issue
I'd like to propose adding the InvisibleID attr to UsdGeomPoints, to mirror what UsdGeomPointInstancer has. Often it's useful to modify a point set without reauthoring the whole thing, without necessarily needing an instancer or a geomsubset.
e.g on a layer you could opt to isolate or remove a subset of points. This is really useful for data cleanup and the like without causing a semantic change in the hierarchy. The current alternative is to reauthor the various points attribute which can be quite wasteful for very large point sets.
This didn't feel like a big enough request to put in USD Proposals, but let me know if you'd like me to move it there.
On the data level, it would essentially be copying the same attrs over from UsdGeomPointInstancer : https://openusd.org/dev/api/class_usd_geom_point_instancer.html#abab7826296b1bb8d647439f5bb6f5167
Filed as internal issue #USD-9375
Hey @dgovil , as the person who created invisibleIDs
for PI's, I've always felt it was a bit of an odd duck, but a necessary-at-the-time feature - GeomSubsets were way off in the future at that point. We've since had several discussions about how we would prefer Subsets if we were to do it over, and leverage them for other purposes, as well. E.g., with the Points primitive, it would allow you to assign a different material to different sets of points, additionally.
That undertaking is a much bigger one, I understand, because currently GeomSubset is not Imageable, so it's not possible to express a visibility opinion on it; there have been several external and internal discussions expressing the desirability of this, and we'd need to sort out what to do about purpose
on GeomSubsets if we were to make such a change.
But let me first ask if you object to that based on the statement "without causing a semantic change in the hierarchy"? Adding the GeomSubset is understandably a change that might force a renderer to resync the parent gprim, but it can still be done non-destructively to an asset/scene, and once it exists, updating the indices
attribute on the GeomSubset should be equivalent to messing with invisibleIDs
-- noting that the current points
type in GeomSubset would refer to points by index, not ID, and that we'd also probably want to add an ids
element type in support of Points and PointInstancer...
@spiffmon I think GeomSubsets would work if we could handle visibility there. My comment about the semantic hierarchy was more about switching to a PointInstancer instead.
I think your suggestion makes a lot of sense and feels more generalizable.
Regarding index vs id, I wonder if it would make sense to have ids implicitly default to index if not specified? I didn't see that documented somewhere, but it felt somewhat intuitive to me.