Repository navigation
USD Logic #120
|
I let AI analyse my code and here is what it says:; Instancing — Your inherits clones entire subtrees (deep copy), meaning 500 identical doors = 500 copies of the same geometry in memory. USD's native instancing shares geometry buffers. For large buildings this is a major memory/performance gap. References (references arc) — You only have inherits. USD references let you compose prims from other files/layers without cloning. IFCX federation uses this for cross-file element reuse. You flatten everything into one namespace instead. Material binding — You store diffuseColor as a flat attribute. USD has rel material:binding pointing to UsdShade material prims with full PBR (metallic, roughness, emissive, textures). Your materials are diffuse-only with no shared material definitions. Primvars — No per-vertex UV coordinates, per-face material indices, or custom vertex attributes. This matters for textured geometry and multi-material meshes. def vs over semantics — Your composition treats all prims the same. In USD, over is an opinion overlay (only modifies existing prims), while def defines new prims. This distinction is important for non-destructive layer edits — your flattening works but loses this nuance. Do you think, we shall consider to implement these? |
Replies: 1 comment 1 reply
This is certainly a problem, but of the implementation not of the spec. I would solve this at the data-model level using a proper Copy-On-Write data structure. That way implementation of broadcasting data over the inheritance edges remains as is, but the COW data structure makes sure that copies are only made when local overrides require different state.
I'm not convinced we need the distinction. For me references is a special case of inherits with differences wrt to strength and all, but especially the multi-disciplinary with fragmented sources of truth for me makes inherits extra valuable to compose the identity of an object out of the fragmented view that each discipline as.
We have example files with PBR. This is a schema level concern that can be resolved later.
I don't think we need this kind of complexity into the IFC5 spec. Basic UV coords with linear interpolation over triangles makes sense, but that's about it, I don't think this needs a spec-level concept.
We indeed went from USD def/class/over into a more simplistic view where based on incoming inheritance/children edges the nature of the primitive is automatically determined. For me this is more a matter of taste, I can live with both. |
This is certainly a problem, but of the implementation not of the spec. I would solve this at the data-model level using a proper Copy-On-Write data structure. That way implementation of broadcasting data over the inheritance edges remains as is, but the COW data structure makes sure that copies are only made when local overrides require different state.
I'm not convinced we need the distinction. For me references is a special case of inherits with differences wrt to strength and all, but especially the multi-disciplinary with fragmented sources of truth for me makes inhe…