Overview
The IFCBIM library provides C++ classes based on IFC 4x3 ADD2 published as ISO 16739-1:2024, with automatic handling of differences when reading and writing as older IFC editions.
In general, the changes made to widely-used definitions tend to be upwardly compatible so that older file data can still be read. New attributes are usually added at the end of an entity. We have full migration support for this type of change and the correct number of attributes will be read or written for both IFC4 and IFC2x3. More dramatic changes are also supported, but to a lesser degree.
For example, IfcMaterial only had a “Name” attribute in IFC2x3, while IFC4 adds description and category fields. Writing as each version would give the following:
#50445= IFCMATERIAL('myname'); /* IFC2x3 */ #50445= IFCMATERIAL('myname', 'mydesc', 'mycat'); /* IFC4 */
Changes in IFC4x3
IFC4x3 adds many new entities for rail and roadway design purposes, with some restructuring and renaming. Changes that might affect your existing code are noted below.
The following simple subtypes (no extra attributes) were deleted by IFC4x3. We have added aliases so that we can read files that use old subtype as the still supported supertype. IfcWallStandardCase is still present.
IfcBeamStandardCase -> IfcBeam IfcColumnStandardCase -> IfcColumn IfcDoorStandardCase -> IfcDoor IfcMemberStandardCase -> IfcMember IfcOpeningStandardCase -> IfcOpening IfcPlateStandardCase -> IfcPlate IfcSlabElementedCase -> IfcSlab IfcSlabStandardCase -> IfcSlab IfcWallElementedCase -> IfcWall IfcWindowStandardCase -> IfcWindow
The IfcBuiltElement and IfcBuiltElementType names replace the previous IfcBuildingElement and IfcBuildingElementType definitions. This appears to be just a simple symbol change.
The IfcCompositeCurve segments attribute has changed to be a list of a supertype of IfcCompositeCurveSegment, which will impact code that uses it. It is now a list of IfcSegment, which is a supertype of composite curve segment and a new curve segment type, so you must cast the contents before use. Some conditional code with the old and new usage is shown below.
IfcCompositeCurve * curve unsigned i,sz; #ifdef IFCLIB_SCHEMA_HAS_IFC4X3 ListOfIfcSegment * segs = curve->Segments(); #else ListOfIfcCompositeCurveSegment * segs = curve->Segments(); #endif for (i=0, sz=segs->size(); i<sz; i++) { #ifdef IFCLIB_SCHEMA_HAS_IFC4X3 IfcCompositeCurveSegment * seg = ROSE_CAST(IfcCompositeCurveSegment, segs->get(i)); if (!seg) continue; /* might be another subtype */ #else IfcCompositeCurveSegment * seg = segs->get(i); #endif /* process curve */ }
The definition of Location in axis placements has changed to the IfcPoint supertype, rather than the more specific IfcCartesianPoint subtype. This may require additional C++ casting, but our ifcx_xform_put() and ifcx_vec_put() functions simplify working with these.
IFC4x3 retired IfcPresentationStyleAssignment and simplified IfcStyledItem by making the Styles attribute only refer to a IfcPresentationStyle rather than a select of style or style assignment. That might simplify new data, but the old usage is found in data from all prior versions. We have retained style assignment and the select type in the Styles attribute.
IFC4x3 ADD2 is the latest revision and makes some minor changes to definitions and where rules. It renames values in the IfcAnnotationTypeEnum and IfcRailwayPartTypeEnum enums. It adds several new values to the IfcArithmeticOperatorEnum and IfcReferentTypeEnum enums. Finally it moves the GeodeticDatum attribute from subtypes IfcGeographicCRS and IfcProjectedCRS to the IfcCoordinateReferenceSystem supertype. No P21 accommodation is needed because the data looks the same. IfcGeographicCRS also has new optional unit.
Changes in IFC4x2
IFC4x2 adds many new entities for bridge design purposes, along with new bridge-oriented elements in many enumerations.
The class hierarchy of some entities have been changed, with intermediate supertypes inserted for categorization. The new types do not have any attributes. The IfcFacility type was inserted between IfcBuilding and IfcSpatialStructure. The IfcDeepFoundation type was inserted between IfcPile and IfcBuildingElement. Similar insertions were done for IfcFacilityPart and IfcPileType.
The definition for IfcObjectPlacement has changed, moving the "PlacementRelTo" attribute from IfcLocalPlacement up to the supertype. This insertion affects the IfcGridPlacement and IfcLinearPlacement definitions in a way that causes noticable Part 21 file differences. Instances in a file have the new attribute inserted into the middle of the list rather than at the end where it might be easily ignored by unsuspecting implementations. The IFCBIM library will read and write IfcGridPlacement and IfcLinearPlacement with the new field in the correct place if the schema type is declared as 4x2 and will omit it for earlier versions. The IfcLinearPlacement curve attribute previously called "PlacementRelTo" has been renamed to "PlacementMeasuredAlong".
Changes from IFC4 to IFC4 addendum 1
The original IFC4 introduced the IfcTriangulatedFaceSet definition, but in IFC4 addendum one, one attribute was deleted and replaced with a new attribute with a completely different structure and meaning. Originally the last attribute was:
NormalIndex LIST OF LIST OF INTEGER
In all subsequent versions (IFC4 addendum one and two, IFC4x1) the last attribute is now:
PnIndex LIST OF IfcPositiveInteger
The IFCBIM library uses the latest schema, so IfcTriangulatedFaceSet has the PnIndex definition, but starting with the v18 release, we can now read old data with the original definition.
The C++ class now also contains the older NormalIndex attribute. When reading a file, the NormalIndex field will be set if the file uses the older list of list of integers, otherwise PhIndex will be set.
The NormalIndex field is always ignored when writing data to a file. Only the PnIndex attribute will be written.
Changes from IFC2x3 to IFC4
Supported migrations are described below.
Definition | IFCBIM Handling |
---|---|
IFC2x3 types removed in IFC4. Simple subtypes with no extra fields, so will be read as an instance of the supertype | |
IfcBezierCurve | handle as IfcBsplineCurve |
IfcRationalBezierCurve | handle as IfcBsplineCurve |
Ifc2DCompositeCurve | handle as IfcCompositeCurve |
IFC2x3 types removed in IFC4, but retained for legacy use. | |
IfcElectricDistributionPoint | Was only flow controller subtype in 2x3. Was replaced by a different set of subtypes. Retained for reading legacy data, but do not use in IFC4 files. |
IfcElectricDistributionPointFunctionEnum | supporting enum for above. |
IFC4-added fields. The extra fields listed below are ignored when reading or writing as IFC2x3. | |
IfcActionRequest | PredefinedType, Status, LongDescription |
IfcBeam | PredefinedType |
IfcBuildingElementPart | PredefinedType |
IfcClassification | Description, Location, ReferenceTokens (date change ignored) |
IfcClassificationReference | Description, Sort |
IfcColumn | PredefinedType |
IfcCostItem | PredefinedType, CostValues, CostQuantities |
IfcCurtainWall | PredefinedType |
IfcCurveStyle | ModelOrDraughting |
IfcDiscreteAccessory | PredefinedType |
IfcDiscreteAccessoryType | PredefinedType |
IfcDistributionChamberElement | PredefinedType |
IfcDistributionPort | PredefinedType, SystemType |
IfcDocumentReference | Description, ReferencedDocument |
IfcDoor | PredefinedType, OperationType, UserDefinedOperationType |
IfcDoorLiningProperties | LiningToPanelOffsetX, LiningToPanelOffsetY |
IfcFastener | PredefinedType |
IfcFastenerType | PredefinedType |
IfcFillAreaStyle | ModelOrDraughting |
IfcFurnitureType | PredefinedType |
IfcGrid | PredefinedType |
IfcIShapeProfileDef | FlangeEdgeRadius, FlangeSlope |
IfcLibraryReference | Description, Language, ReferencedLibrary |
IfcMaterial | Description, Category |
IfcMaterialLayer | Name, Description, Category, Priority |
IfcMaterialLayerSet | Description |
IfcMaterialLayerSetUsage | ReferenceExtent |
IfcMechanicalFastener | PredefinedType |
IfcMechanicalFastenerType | PredefinedType, NominalDiameter, NominalLength |
IfcMember | PredefinedType |
IfcMetric | ReferencePath (date change ignored) |
IfcOpeningElement | PredefinedType |
IfcPerformanceHistory | LifeCyclePhase, PredefinedType |
IfcPermit | PredefinedType, Status, LongDescription |
IfcPlate | PredefinedType |
IfcProjectOrder | LongDescription |
IfcProjectionElement | PredefinedType |
IfcPropertyBoundedValue | SetPointValue |
IfcPropertyTableValue | CurveInterpolation |
IfcQuantityArea | Formula |
IfcQuantityCount | Formula |
IfcQuantityLength | Formula |
IfcQuantityTime | Formula |
IfcQuantityVolume | Formula |
IfcQuantityWeight | Formula |
IfcRampFlight | PredefinedType |
IfcReinforcingMesh | PredefinedType |
IfcStairFlight | PredefinedType |
IfcStructuralCurveConnection | Axis |
IfcStructuralCurveMember | Axis |
IfcStructuralPointConnection | ConditionCoordinateSystem |
IfcSystemFurnitureElementType | PredefinedType |
IfcTable | Columns |
IfcTelecomAddress | MessagingIDs |
IfcTendonAnchor | PredefinedType |
IfcTextStyle | ModelOrDraughting |
IfcWall | PredefinedType |
IfcWallStandardCase | PredefinedType |
IfcWindow | PredefinedType, PartitioningType, UserDefinedPartitioningType |
IfcWindowLiningProperties | LiningOffset, LiningToPanelOffsetX, LiningToPanelOffsetY |
IfcZone | LongName |
Other Changes
The BuildingSmart team chose to make non-upward compatible changes to IFC 2x3 definitions that were not widely-used or supported by commercial software. Some of these changes, like replacing date/time objects with a simple string, are meant to simplify implementation. Other changes reorganize relationships between object so make room for future expansion.
Since the pool of existing data is limited and the differences are significant, the IFCBIM library does not contain automatic migration for the following version changes.
ENTITY IfcAnnotationFillAreaOccurrence DEL GlobalOrLocal : OPTIONAL IfcGlobalOrLocalEnum; ENTITY IfcAppliedValue Changed date values to strings ADD Category : OPTIONAL IfcLabel; ADD Condition : OPTIONAL IfcLabel; ADD ArithmeticOperator : OPTIONAL IfcArithmeticOperatorEnum; ADD Components : OPTIONAL LIST [1:?] OF IfcAppliedValue; ENTITY IfcApproval; REORDERS ATTS ADD RequestingApproval : OPTIONAL IfcActorSelect; ADD GivingApproval : OPTIONAL IfcActorSelect; ENTITY IfcApprovalRelationship CHANGES SUPER, CHANGES ATTS ENTITY IfcAsymmetricIShapeProfileDef CHANGES SUPER, CHANGES ATTS ENTITY IfcBuildingElementProxy NOW PredefinedType : OPTIONAL IfcBuildingElementProxyTypeEnum; WAS CompositionType : OPTIONAL IfcElementCompositionEnum; ENTITY IfcConstructionEquipmentResource ADD PredefinedType : OPTIONAL IfcConstructionEquipmentResourceTypeEnum; ENTITY IfcConstructionMaterialResource DEL Suppliers : OPTIONAL SET [1:?] OF IfcActorSelect; DEL UsageRatio : OPTIONAL IfcRatioMeasure; ADD PredefinedType : OPTIONAL IfcConstructionMaterialResourceTypeEnum; ENTITY IfcConstructionProductResource ADD PredefinedType : OPTIONAL IfcConstructionProductResourceTypeEnum; ENTITY IfcConstructionResource NOW Usage : OPTIONAL IfcResourceTime; NOW BaseCosts : OPTIONAL LIST [1:?] OF IfcAppliedValue; NOW BaseQuantity : OPTIONAL IfcPhysicalQuantity; WAS ResourceIdentifier : OPTIONAL IfcIdentifier; WAS ResourceGroup : OPTIONAL IfcLabel; WAS ResourceConsumption : OPTIONAL IfcResourceConsumptionEnum; WAS BaseQuantity : OPTIONAL IfcMeasureWithUnit; ENTITY IfcControl ADD Identification : OPTIONAL IfcIdentifier; ENTITY IfcCostSchedule NOW PredefinedType : OPTIONAL IfcCostScheduleTypeEnum; NOW Status : OPTIONAL IfcLabel; NOW SubmittedOn : OPTIONAL IfcDateTime; NOW UpdateDate : OPTIONAL IfcDateTime; WAS SubmittedBy : OPTIONAL IfcActorSelect; WAS PreparedBy : OPTIONAL IfcActorSelect; WAS SubmittedOn : OPTIONAL IfcDateTimeSelect; WAS Status : OPTIONAL IfcLabel; WAS TargetUsers : OPTIONAL SET [1:?] OF IfcActorSelect; WAS UpdateDate : OPTIONAL IfcDateTimeSelect; WAS ID : IfcIdentifier; WAS PredefinedType : IfcCostScheduleTypeEnum; ENTITY IfcCostValue DEL CostType : IfcLabel; DEL Condition : OPTIONAL IfcText; ENTITY IfcCrewResource ADD PredefinedType : OPTIONAL IfcCrewResourceTypeEnum; ENTITY IfcCShapeProfileDef DEL CentreOfGravityInX : OPTIONAL IfcPositiveLengthMeasure; ENTITY IfcDistributionControlElement DEL ControlElementId : OPTIONAL IfcIdentifier; ENTITY IfcDocumentInformation REWORKED ATTS DEL DocumentReferences : OPTIONAL SET [1:?] OF IfcDocumentReference; ADD Location : OPTIONAL IfcURIReference; (string) ENTITY IfcIrregularTimeSeriesValue; ADD TimeStamp : IfcDateTime; CHANGED ListValues : LIST [1:?] OF IfcValue; ENTITY IfcLaborResource DELETE SkillSet : OPTIONAL IfcText; ADD PredefinedType : OPTIONAL IfcLaborResourceTypeEnum; ENTITY IfcLibraryInformation DEL LibraryReference : OPTIONAL SET [1:?] OF IfcLibraryReference; ADD Location : OPTIONAL IfcURIReference; ADD Description : OPTIONAL IfcText; ENTITY IfcLShapeProfileDef DEL CentreOfGravityInX : OPTIONAL IfcPositiveLengthMeasure; DEL CentreOfGravityInY : OPTIONAL IfcPositiveLengthMeasure; ENTITY IfcMonetaryUnit; CHANGE Currency : IfcLabel; enum to label ENTITY IfcObjective ADD LogicalAggregator : OPTIONAL IfcLogicalOperatorEnum; DEL ResultValues : OPTIONAL IfcMetric; ENTITY IfcProcedure DEL ProcedureID : IfcIdentifier; DEL ProcedureType : IfcProcedureTypeEnum; DEL UserDefinedProcedureType : OPTIONAL IfcLabel; ADD PredefinedType : OPTIONAL IfcProcedureTypeEnum; ENTITY IfcProcess ADD Identification : OPTIONAL IfcIdentifier; ADD LongDescription : OPTIONAL IfcText; ENTITY IfcProfileProperties ADD SUPER WITH NEW ATTS DEL ProfileName : OPTIONAL IfcLabel; ENTITY IfcProject CHANGE SUPER to IfcContext INHERITS NEW ObjectType : OPTIONAL IfcLabel; ENTITY IfcPropertyDependencyRelationship; DEL Name : OPTIONAL IfcLabel; may move to new super DEL Description : OPTIONAL IfcText; ENTITY IfcRelSequence CHANGE LagTime from floating point value to an object reference ADD UserDefinedSequenceType : OPTIONAL IfcLabel; ENTITY IfcResource ADD Identification : OPTIONAL IfcIdentifier; ADD LongDescription : OPTIONAL IfcText; ENTITY IfcSpace DEL InteriorOrExteriorSpace : IfcInternalOrExternalEnum; ADD PredefinedType : OPTIONAL IfcSpaceTypeEnum; (may be the same basic vals) ENTITY IfcStructuralAction DEL CausedBy : OPTIONAL IfcStructuralReaction; ENTITY IfcStructuralAnalysisModel ADD SharedPlacement : OPTIONAL IfcObjectPlacement; ENTITY IfcStructuralLinearAction DEL ProjectedOrTrue : IfcProjectedOrTrueLengthEnum; ENTITY IfcStructuralSurfaceMemberVarying DEL SubsequentThickness : LIST [2:?] OF IfcPositiveLengthMeasure; DEL VaryingThicknessLocation : IfcShapeAspect; ENTITY IfcSubContractResource DEL SubContractor : OPTIONAL IfcActorSelect; DEL JobDescription : OPTIONAL IfcText; ADD PredefinedType : OPTIONAL IfcSubContractResourceTypeEnum; ENTITY IfcSurfaceTexture ADD PARAMETER : OPTIONAL LIST [1:?] OF IfcIdentifier; ENTITY IfcTask DEL/MOVE? TaskId : IfcIdentifier; ADD TaskTime : OPTIONAL IfcTaskTime; ADD PredefinedType : OPTIONAL IfcTaskTypeEnum; ENTITY IfcTextureCoordinate ADD Maps : LIST [1:?] OF IfcSurfaceTexture; ENTITY IfcTextureMap DEL TextureMaps : SET [1:?] OF IfcVertexBasedTextureMap; ADD Vertices : LIST [3:?] OF IfcTextureVertex; ADD MappedTo : IfcFace; ENTITY IfcTransportElement DEL OperationType : OPTIONAL IfcTransportElementTypeEnum; DEL CapacityByWeight : OPTIONAL IfcMassMeasure; DEL CapacityByNumber : OPTIONAL IfcCountMeasure; ADD PredefinedType : OPTIONAL IfcTransportElementTypeEnum; ENTITY IfcTShapeProfileDef DEL CentreOfGravityInY : OPTIONAL IfcPositiveLengthMeasure; ENTITY IfcUShapeProfileDef DEL CentreOfGravityInX : OPTIONAL IfcPositiveLengthMeasure; ENTITY IfcWorkControl DEL/MOVE? Identifier : IfcIdentifier; DEL WorkControlType : OPTIONAL IfcWorkControlTypeEnum; DEL UserDefinedControlType : OPTIONAL IfcLabel; ENTITY IfcWorkPlan ADD PredefinedType : OPTIONAL IfcWorkPlanTypeEnum; ENTITY IfcWorkSchedule ADD PredefinedType : OPTIONAL IfcWorkScheduleTypeEnum;
Deleted Entities
The following IFC2x3 and 2x2 entities are no longer in the IFC4 model. They are not present in the class library but could be restored for migration support if needed by specific applications.
- IfcAnnotationSurface
- IfcAnnotationOccurrence
- IfcAnnotationSymbolOccurrence
- IfcAnnotationTextOccurrence
- IfcAppliedValueRelationship;
- IfcApprovalActorRelationship;
- IfcApprovalPropertyRelationship;
- IfcCalendarDate;
- IfcChamferEdgeFeature
- IfcClassificationItem;
- IfcClassificationItemRelationship;
- IfcClassificationNotation;
- IfcClassificationNotationFacet;
- IfcCondition
- IfcConditionCriterion
- IfcConnectionPortGeometry
- IfcConstraintAggregationRelationship;
- IfcConstraintClassificationRelationship;
- IfcConstraintRelationship;
- IfcCoordinatedUniversalTimeOffset;
- IfcDateAndTime;
- IfcDefinedSymbol
- IfcDiameterDimension
- IfcDimensionCalloutRelationship
- IfcDimensionCurve
- IfcDimensionCurveDirectedCallout
- IfcDimensionCurveTerminator
- IfcDimensionPair
- IfcDocumentElectronicFormat;
- IfcDraughtingCallout
- IfcDraughtingCalloutRelationship
- IfcDraughtingPreDefinedTextFont
- IfcEdgeFeature
- IfcElectricalBaseProperties
- IfcElectricalCircuit
- IfcElectricalElement
- IfcElectricDistributionPoint — added 2018-04-12
- IfcElectricHeaterType
- IfcEnergyProperties
- IfcEnvironmentalImpactValue
- IfcEquipmentElement
- IfcEquipmentStandard
- IfcExtendedMaterialProperties
- IfcExternallyDefinedSymbol
- IfcFillAreaStyleTileSymbolWithStyle
- IfcFluidFlowProperties
- IfcFuelProperties
- IfcFurnitureStandard
- IfcGasTerminalType
- IfcGeneralMaterialProperties
- IfcGeneralProfileProperties
- IfcHygroscopicMaterialProperties
- IfcLinearDimension
- IfcLocalTime;
- IfcMaterialDefinitionRepresentation
- IfcMechanicalConcreteMaterialProperties
- IfcMechanicalMaterialProperties
- IfcMechanicalSteelMaterialProperties
- IfcMove
- IfcOneDirectionRepeatFactor
- IfcOpticalMaterialProperties
- IfcOrderAction
- IfcPreDefinedDimensionSymbol
- IfcPreDefinedPointMarkerSymbol
- IfcPreDefinedSymbol
- IfcPreDefinedTerminatorSymbol
- IfcProductsOfCombustionProperties
- IfcProjectionCurve
- IfcProjectOrderRecord
- IfcPropertyConstraintRelationship;
- IfcRadiusDimension
- IfcReferencesValueDocument;
- IfcRelAssignsTasks
- IfcRelAssignsToProjectOrder
- IfcRelAssociatesAppliedValue
- IfcRelaxation;
- IfcRelConnectsStructuralElement -- 3 only
- IfcRelInteractionRequirements
- IfcRelOccupiesSpaces
- IfcRelOverridesProperties
- IfcRelSchedulesCostItems
- IfcRibPlateProfileProperties
- IfcRoundedEdgeFeature
- IfcScheduleTimeControl
- IfcServiceLife
- IfcServiceLifeFactor
- IfcSoundProperties
- IfcSoundValue
- IfcSpaceProgram
- IfcSpaceThermalLoadProperties
- IfcStructuralLinearActionVarying
- IfcStructuralPlanarActionVarying
- IfcStructuralProfileProperties
- IfcStructuralSteelProfileProperties
- IfcStructuredDimensionCallout
- IfcSymbolStyle
- IfcTerminatorSymbol
- IfcTextStyleWithBoxCharacteristics;
- IfcTextStyleWithMirror; -- 2 only
- IfcTextStyleWithSpacing; -- 2 only
- IfcThermalMaterialProperties
- IfcTimeSeriesReferenceRelationship;
- IfcTimeSeriesSchedule
- IfcTwoDirectionRepeatFactor
- IfcVertexBasedTextureMap;
- IfcWaterProperties