The IFC file bytes, either raw or behind IfcSourceBytes
Entity index with byId and byType maps
OptionalprojectId: number
Optional express id of the specific IFCPROJECT to read
units from. Most files declare exactly one, so the default (the file's
first IFCPROJECT) is correct for the overwhelmingly common case; pass
this explicitly when resolving units for an entity that may belong to a
later IFCPROJECT in a multi-project (federated-merge, see #1332) file
— see resolveOwningIfcProjectId.
Scale factor to apply to length values (e.g., 0.001 for millimeters)
Extract length unit scale factor from IFC file
Follows the chain: IFCPROJECT → IFCUNITASSIGNMENT → IFCSIUNIT/IFCCONVERSIONBASEDUNIT Returns the multiplier to convert coordinates to meters.
Every
1.0this function returns for a path OTHER than "IFCSIUNIT length unit with no prefix" is an unconfirmed default, not a confirmed metre declaration — those paths call warnUnknownUnit exactly once perentityIndexso the ambiguity is visible instead of silent (#2104). The no-prefix IFCSIUNIT case is a genuine, confirmed "this file declares meters" and intentionally does not warn.