Expand description
Unit extraction and conversion for IFC files
Handles parsing of IFCSIUNIT and IFCCONVERSIONBASEDUNIT (imperial units) and applying appropriate multipliers to geometry coordinates.
Functions§
- extract_
length_ unit_ scale - Extract length unit scale factor from IFC file
- extract_
plane_ angle_ to_ radians - Extract the multiplier that converts file plane-angle units to radians.
- get_
conversion_ based_ unit_ factor - The unit-label tables live in [
crate::unit_labels], shared with the georeferencing MapUnit reader; re-exported here so theunits::paths callers already use keep working. Known conversion factors for imperial/conversion-based units to meters These are the standard conversions defined in IFC specification - get_
si_ prefix_ multiplier - The unit-label tables live in [
crate::unit_labels], shared with the georeferencing MapUnit reader; re-exported here so theunits::paths callers already use keep working. SI Prefix multipliers as defined in IFC specification. Maps IfcSIPrefix enum values to their numeric multipliers; an absent or unrecognised prefix means the base unit (metres), i.e. 1.0. Callers that must distinguish those two cases wanttry_si_prefix_multiplier. - try_
extract_ length_ unit_ scale - Resolve the length-unit scale ONLY when the full unit chain (IFCPROJECT → IFCUNITASSIGNMENT → IFCSIUNIT) is decodable from the decoder’s current index.
- try_
extract_ plane_ angle_ to_ radians - Partial-index-safe sibling of
extract_plane_angle_to_radians. - try_
si_ prefix_ multiplier - The unit-label tables live in [
crate::unit_labels], shared with the georeferencing MapUnit reader; re-exported here so theunits::paths callers already use keep working. SI Prefix multiplier for a member of theIfcSIPrefixEXPRESS enumeration, orNonewhen the string is not one of its sixteen members.