Compute the root entity set and hidden product IDs for a visible-only export.
Returns:
roots: Entity IDs that form the seed set for the reference closure.
Includes infrastructure, spatial structure, relationship entities, and
visible product entities.
hiddenProductIds: Product entity IDs that are hidden/not isolated.
These should be passed as excludeIds to collectReferencedEntityIds
to prevent the closure from walking into hidden products' geometry.
Also propagates hidden status from building elements to their openings
via IfcRelVoidsElement, so orphaned openings are excluded.
Pass index (an EffectiveEntityIndex) to classify the model the session
will actually save: overlay-created entities become roots by the same type
rules as parsed ones, tombstoned entities are gone, and a retyped entity is
classified by its NEW class. Without it, classification runs over the source
buffer alone and a created wall can never be a root — it is not in the index,
and nothing in the source references it, so visibleOnly dropped it from the
file with no error and no warning (#2012).
Compute the root entity set and hidden product IDs for a visible-only export.
Returns:
roots: Entity IDs that form the seed set for the reference closure. Includes infrastructure, spatial structure, relationship entities, and visible product entities.hiddenProductIds: Product entity IDs that are hidden/not isolated. These should be passed asexcludeIdstocollectReferencedEntityIdsto prevent the closure from walking into hidden products' geometry.Also propagates hidden status from building elements to their openings via IfcRelVoidsElement, so orphaned openings are excluded.
Pass
index(anEffectiveEntityIndex) to classify the model the session will actually save: overlay-created entities become roots by the same type rules as parsed ones, tombstoned entities are gone, and a retyped entity is classified by its NEW class. Without it, classification runs over the source buffer alone and a created wall can never be a root — it is not in the index, and nothing in the source references it, sovisibleOnlydropped it from the file with no error and no warning (#2012).