Skip to content

Commit b27a1b9

Browse files
authored
Merge pull request #800 from Autodesk/babio/23_4_update
IFC 23.4 Update
2 parents b647e72 + 13d174c commit b27a1b9

File tree

120 files changed

+10352
-7903
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

120 files changed

+10352
-7903
lines changed
Binary file not shown.

Install/Program Files to Install/bundle/Contents/Resources/ADSKIFCExporterHelp.htm

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -237,6 +237,72 @@ <h3>Support Information</h3>
237237
<h2 id="VersionHistory" name="VersionHistory">Version History</h2>
238238

239239
<div class="versionset">
240+
<div class="version">23.4.0.0</div><div class="versioninfo-bullet">
241+
<br><p>
242+
General:
243+
<ul>
244+
<li>This is the first version of IFC Exporter for Revit 2023.
245+
<li>It contains a various improvements and bug fixes for the basic Revit 2023.
246+
</ul>
247+
</p>
248+
<br>
249+
<p>
250+
Improvements:
251+
<ul>
252+
<li>Added filename to the journal when export IFC if the default is used.
253+
<li>Added information to IfcOwnerHistory when exporting to IFC.
254+
<li>Add new user defined units export.
255+
<li>Added Revit Content Identifier to IFC export.
256+
<li>Added Width as an exported quantity to IFC for some assembly-based walls.
257+
<li>Allowed export of some elements to IFC4 Reference View [Structural] that had no material assignments.
258+
<li>Allowed some old IFC configuration settings to be upgraded.
259+
<li>Changed the behavior of the warning message when exporting to IFC 4 if elements in a Revit model are far from the origin so that the warning appears only if an EPSG code is also set.
260+
<li>Implemented unique and consistent naming for IfcShapeAspect and IfcMaterialConstituent pairs.
261+
<li>Improved area and volume base quantities export for slabs as part of the roof.
262+
<li>Improved exporting all layers of some walls to IFC 4 when the option to split by level was chosen.
263+
<li>Improved stability of exporting to IFC when the Revit model has corrupted extensible storage data.
264+
<li>Improved stability when exporting files to IFC with some short, invalid IFC entity names set in the Export to IFC As and Export Type to IFC As parameters.
265+
<li>Improved support for adding properties to PSet_ZoneCommon.
266+
<li>Improved the color assignments for some elements exported to IFC 4.
267+
<li>Improved the export of current view only IFC files when the phase of the view has changed since it was first set in the IFC export settings.
268+
</ul>
269+
</p>
270+
<br>
271+
<p>
272+
Bug Fixes:
273+
<ul>
274+
<li>Added type parameter set export for Revit elements whose corresponding IFC 2x3 entity didn't have a type entity associated with it, such as ramps, stairs, and footings.
275+
<li>Corrected placement of some families inside assemblies when exporting to IFC.
276+
<li>Fixed a shifting of TriangulatedFaceSet geometry elements.
277+
<li>Fixed body representation for walls export to the IFC4RV.
278+
<li>Fixed bug with renaming IFC configuration makes the revit-session remember the old and the new IFC configuration.
279+
<li>Fixed classifications export for systems.
280+
<li>Fixed export of linked file orientation when exporting linked files to the same site.
281+
<li>Fixed export of model line placement elevation for 2D representation.
282+
<li>Fixed export of room elevation.
283+
<li>Fixed export of walls with openings placed next to clippings.
284+
<li>Fixed export of GrossArea to IFC4 QTO base quantities for Revit walls exported as IfcCovering.
285+
<li>Fixed a IsExternal parameter for windows exported to IFC.
286+
<li>Fixed a placement of beam openings.
287+
<li>Fixed the processing of the Export to IFC parameter for the assemblies.
288+
<li>Fixed Width parameter for IfcSlab and IfcCovering exported to IFC4 QTO base quantities.
289+
<li>Improved base quantities calculation for slab elements with openings.
290+
<li>Improved base quantities calculation for spatial elements.
291+
<li>Improved calculations of gross volume and gross side area when exporting some walls with openings to IFC 4.
292+
<li>Improved error handling for invalid Revit file with missing project base and survey points.
293+
<li>Improved export of some beams to IFC where the geometry was previously inverted in the IFC file.
294+
<li>Improved export of some beams with openings to IFC 4.
295+
<li>Improved export of some missing elements when exporting linked documents to IFC.
296+
<li>Improved the export of some walls that had doors or windows with multiple voids in the original family.
297+
<li>Improved performance of some elongated elements export to IFC 4.
298+
<li>Improved linking invalid IFC files with unbounded curves as part of their geometric representations.
299+
<li>Removed some IFC export configuration settings that didn't get properly renamed or deleted by Revit.
300+
</ul>
301+
</p>
302+
<br>
303+
</div>
304+
<br>
305+
240306
<div class="version">23.3.1.0</div><div class="versioninfo-bullet">
241307
<br><p>
242308
General:
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
<?xml version="1.0" encoding="utf-8"?>
2-
<ApplicationPackage SchemaVersion="1.0" AutodeskProduct="Revit" ProductType="Application" Name="IFC Exporter for Revit" AppVersion="23.3.1.0" Description="This application seamlessly replaces the built-in IFC export capabilities of Revit 2023. " Author="Autodesk" Icon=".\Contents\Resources\IFCExporter.png" AppNameSpace="appstore.exchange.autodesk.com" OnlineDocumentation="http://www.autodesk.com" HelpFile=".\Contents\Resources\ADSKIFCExporterHelp.htm" ProductCode="{40527B9C-60B8-407E-BF56-7AAA67F07ACA}" UpgradeCode="{A27E008E-2278-4F84-BB3B-59C605168900}" SupportedLocales="Enu">
2+
<ApplicationPackage SchemaVersion="1.0" AutodeskProduct="Revit" ProductType="Application" Name="IFC Exporter for Revit" AppVersion="23.4.0.0" Description="This application seamlessly replaces the built-in IFC export capabilities of Revit 2023. " Author="Autodesk" Icon=".\Contents\Resources\IFCExporter.png" AppNameSpace="appstore.exchange.autodesk.com" OnlineDocumentation="http://www.autodesk.com" HelpFile=".\Contents\Resources\ADSKIFCExporterHelp.htm" ProductCode="{40527B9C-60B8-407E-BF56-7AAA67F07ACA}" UpgradeCode="{A27E008E-2278-4F84-BB3B-59C605168900}" SupportedLocales="Enu">
33
<CompanyDetails Name="Autodesk, Inc." Phone=" " Url="http://www.autodesk.com" Email="[email protected]" />
44
<RuntimeRequirements OS="Win64" Platform="Revit" SeriesMin="R2023" SeriesMax="R2023" />
55
<Components Description="2023">
66
<RuntimeRequirements OS="Win64" Platform="Revit" SeriesMin="R2023" SeriesMax="R2023" />
7-
<ComponentEntry AppName="IFC For Revit 2023" Version="23.3.1" ModuleName="./Contents/2023/IFCExporterUIOverride.addin" AppDescription="IFC For Revit 2023" />
8-
<ComponentEntry AppName="IFC For Revit 2023" Version="23.3.1" ModuleName="./Contents/2023/Revit.IFC.addin" AppDescription="IFC For Revit 2023" />
7+
<ComponentEntry AppName="IFC For Revit 2023" Version="23.4.0" ModuleName="./Contents/2023/IFCExporterUIOverride.addin" AppDescription="IFC For Revit 2023" />
8+
<ComponentEntry AppName="IFC For Revit 2023" Version="23.4.0" ModuleName="./Contents/2023/Revit.IFC.addin" AppDescription="IFC For Revit 2023" />
99
</Components>
1010
</ApplicationPackage>

Install/RevitIFCSetupWix/Product.wxs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
33
xmlns:util="http://schemas.microsoft.com/wix/UtilExtension">
44

5-
<Product Id="1A9C2C21-2331-42D2-0000-992E73C12300" Name="Revit IFC 2023" Language="1033" Version="23.3.1.0" Manufacturer="Autodesk" UpgradeCode="1A9C2C21-23B8-42D2-0000-992E73C11B3F">
5+
<Product Id="1A9C2C21-2340-42D2-0000-992E73C12300" Name="Revit IFC 2023" Language="1033" Version="23.4.0.0" Manufacturer="Autodesk" UpgradeCode="1A9C2C21-23B8-42D2-0000-992E73C11B3F">
66
<Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine" />
77

88
<MajorUpgrade DowngradeErrorMessage="A newer version of [ProductName] is already installed." />

Install/RevitIFCSetupWix/RevitIFCSetupWix.wixproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<ProductVersion>3.8</ProductVersion>
77
<ProjectGuid>7dfbd495-c588-4c7b-b8f6-5b793adb06f2</ProjectGuid>
88
<SchemaVersion>2.0</SchemaVersion>
9-
<OutputName>IFC for Revit 2023.3.1.0</OutputName>
9+
<OutputName>IFC for Revit 2023.4.0.0</OutputName>
1010
<OutputType>Package</OutputType>
1111
<WixTargetsPath Condition=" '$(WixTargetsPath)' == '' AND '$(MSBuildExtensionsPath32)' != '' ">$(MSBuildExtensionsPath32)\Microsoft\WiX\v3.x\Wix.targets</WixTargetsPath>
1212
<WixTargetsPath Condition=" '$(WixTargetsPath)' == '' ">$(MSBuildExtensionsPath)\Microsoft\WiX\v3.x\Wix.targets</WixTargetsPath>

Install/RevitIFCSetupWix/buildInstaller.bat

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@ rem It is necessary to add the Wix bin directory to the system path temporarily
1111
SET PATH=%PATH%;%WixRoot%
1212

1313
candle.exe -dProjectDir=%2 -ext WixUtilExtension %2Product.wxs
14-
light.exe -ext WixUtilExtension -out RevitIFC2023.3.1.msi product.wixobj -ext WixUIExtension
14+
light.exe -ext WixUtilExtension -out RevitIFC2023.4.0.msi product.wixobj -ext WixUIExtension
1515

16-
copy RevitIFC2023.3.1.msi %1..\Releasex64
17-
del RevitIFC2023.3.1.msi
16+
copy RevitIFC2023.4.0.msi %1..\Releasex64
17+
del RevitIFC2023.4.0.msi
1818

19-
echo %1..\Releasex64\RevitIFC2023.3.1.msi
19+
echo %1..\Releasex64\RevitIFC2023.4.0.msi

Source/IFCExporterUIOverride/IFCCommandOverrideApplication.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,6 @@ public Result OnShutdown(UIControlledApplication application)
5858
{
5959
// Clean up
6060
m_ifcCommandBinding.Executed -= OnIFCExport;
61-
6261
return Result.Succeeded;
6362
}
6463

@@ -103,7 +102,7 @@ private void ApplicationInitialized(object sender, ApplicationInitializedEventAr
103102
entUIService.AddServer(browseIFCEntityServer);
104103
entUIService.SetActiveServer(browseIFCEntityServer.GetServerId());
105104
}
106-
catch {}
105+
catch { }
107106
}
108107
}
109108

Source/IFCExporterUIOverride/IFCExport.xaml.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -507,6 +507,8 @@ private void buttonExport_Click(object sender, RoutedEventArgs args)
507507
return;
508508
}
509509

510+
TheDocument.Application.WriteJournalComment(@"Jrn.Data ""File Name"", ""IDOK"", " + @"""" + textBoxSetupFileName.Text + @"""", true);
511+
510512
IFCExportConfiguration selectedConfig = GetSelectedConfiguration();
511513
if (OptionsUtil.ExportAs4DesignTransferView(selectedConfig.IFCVersion))
512514
{
@@ -527,7 +529,8 @@ private void buttonExport_Click(object sender, RoutedEventArgs args)
527529
selectedConfig = LastSelectedConfig[selectedConfig.Name];
528530

529531
// This check will be done only for IFC4 and above as this only affects IfcMapConversion use that starts in IFC4 onward
530-
if (!OptionsUtil.ExportAsOlderThanIFC4(selectedConfig.IFCVersion))
532+
if (!OptionsUtil.ExportAsOlderThanIFC4(selectedConfig.IFCVersion) &&
533+
!string.IsNullOrWhiteSpace(selectedConfig.GeoRefEPSGCode))
531534
{
532535
// Check whether the resulting offset (to wcs) will be too large due to geo-reference information, raise warning
533536
BasePoint surveyPoint = BasePoint.GetSurveyPoint(TheDocument);

Source/IFCExporterUIOverride/IFCExportConfiguration.cs

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -285,6 +285,15 @@ public KnownERNames ExchangeRequirement
285285
/// </summary>
286286
public bool UseTypeNameOnlyForIfcType { get; set; } = false;
287287

288+
/// <summary>
289+
/// Don't create a container entity for floors and roofs unless exporting parts
290+
/// </summary>
291+
public bool ExportHostAsSingleEntity { get; set; } = false;
292+
293+
/// <summary>
294+
/// Use Author field in Project Information to set IfcOwnerHistory LastModified attribute
295+
/// </summary>
296+
public bool OwnerHistoryLastModified { get; set; } = false;
288297
/// <summary>
289298
/// Value indicating whether the IFC Entity Name will use visible Revit Name
290299
/// </summary>
@@ -562,7 +571,9 @@ public void UpdateBuiltInConfiguration(IFCExportConfiguration updatedConfig)
562571
/// <param name="filterViewId">The id of the view that will be used to select which elements to export.</param>
563572
public void UpdateOptions(IFCExportOptions options, ElementId filterViewId)
564573
{
565-
JavaScriptSerializer ser = new JavaScriptSerializer();
574+
JavaScriptSerializer ser = new JavaScriptSerializer();
575+
options.FilterViewId = VisibleElementsOfCurrentView ? filterViewId : ElementId.InvalidElementId;
576+
566577
foreach (var prop in GetType().GetProperties())
567578
{
568579
switch (prop.Name)
@@ -574,7 +585,7 @@ public void UpdateOptions(IFCExportOptions options, ElementId filterViewId)
574585
options.FileVersion = IFCVersion;
575586
break;
576587
case "ActivePhaseId":
577-
if (IFCPhaseAttributes.Validate(ActivePhaseId))
588+
if (options.FilterViewId == ElementId.InvalidElementId && IFCPhaseAttributes.Validate(ActivePhaseId))
578589
options.AddOption(prop.Name, ActivePhaseId.ToString());
579590
break;
580591
case "SpaceBoundaries":
@@ -601,8 +612,6 @@ public void UpdateOptions(IFCExportOptions options, ElementId filterViewId)
601612
break;
602613
}
603614
}
604-
605-
options.FilterViewId = VisibleElementsOfCurrentView ? filterViewId : ElementId.InvalidElementId;
606615
}
607616

608617

Source/IFCExporterUIOverride/IFCExportConfigurationsMap.cs

Lines changed: 40 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,9 @@ public void AddSavedConfigurations()
185185
Field fieldTessellationLevelOfDetail = m_OldSchema.GetField(s_setupTessellationLevelOfDetail);
186186
if (fieldTessellationLevelOfDetail != null)
187187
configuration.TessellationLevelOfDetail = configEntity.Get<double>(s_setupTessellationLevelOfDetail);
188+
Field fieldOwnerHistoryLastModified = m_OldSchema.GetField(s_ownerHistoryLastModified);
189+
if (fieldOwnerHistoryLastModified != null)
190+
configuration.OwnerHistoryLastModified = configEntity.Get<bool>(s_ownerHistoryLastModified);
188191

189192
AddOrReplace(configuration);
190193
}
@@ -269,6 +272,8 @@ public void AddSavedConfigurations()
269272
configuration.UseVisibleRevitNameAsEntityName = bool.Parse(configMap[s_useVisibleRevitNameAsEntityName]);
270273
if (configMap.ContainsKey(s_useOnlyTriangulation))
271274
configuration.UseOnlyTriangulation = bool.Parse(configMap[s_useOnlyTriangulation]);
275+
if (configMap.ContainsKey(s_ownerHistoryLastModified))
276+
configuration.OwnerHistoryLastModified = bool.Parse(configMap[s_ownerHistoryLastModified]);
272277
if (configMap.ContainsKey(s_setupTessellationLevelOfDetail))
273278
configuration.TessellationLevelOfDetail = double.Parse(configMap[s_setupTessellationLevelOfDetail]);
274279
if (configMap.ContainsKey(s_setupSitePlacement))
@@ -316,6 +321,7 @@ public void AddSavedConfigurations()
316321
catch (Exception)
317322
{
318323
// don't skip all configurations if an exception occurs for one
324+
IFCCommandOverrideApplication.TheDocument.Application.WriteJournalComment("IFC error: Cannot read IFCExportConfigurationMap schema", true);
319325
}
320326
}
321327
}
@@ -376,6 +382,7 @@ public void AddSavedConfigurations()
376382
private const string s_setupSitePlacement = "SitePlacement";
377383
private const string s_useTypeNameOnlyForIfcType = "UseTypeNameOnlyForIfcType";
378384
private const string s_useVisibleRevitNameAsEntityName = "UseVisibleRevitNameAsEntityName";
385+
private const string s_ownerHistoryLastModified = "OwnerHistoryLastModified";
379386
// Used for COBie 2.4
380387
private const string s_cobieCompanyInfo = "COBieCompanyInfo";
381388
private const string s_cobieProjectInfo = "COBieProjectInfo";
@@ -497,52 +504,48 @@ public void UpdateSavedConfigurations(IFCExportConfigurationsMap initialConfigs)
497504
m_jsonSchema = builder.Finish();
498505
}
499506

500-
// It won't start any transaction if there is no change to the configurations
501-
if (setupsToSave.Count > 0)
507+
// Overwrite all saved configs with the new list
508+
Transaction transaction = new Transaction(IFCCommandOverrideApplication.TheDocument, Properties.Resources.UpdateExportSetups);
509+
try
502510
{
503-
// Overwrite all saved configs with the new list
504-
Transaction transaction = new Transaction(IFCCommandOverrideApplication.TheDocument, Properties.Resources.UpdateExportSetups);
505-
try
511+
transaction.Start(Properties.Resources.SaveConfigurationChanges);
512+
IList<DataStorage> savedConfigurations = GetSavedConfigurations(m_jsonSchema);
513+
int savedConfigurationCount = savedConfigurations.Count<DataStorage>();
514+
int savedConfigurationIndex = 0;
515+
foreach (IFCExportConfiguration configuration in setupsToSave)
506516
{
507-
transaction.Start(Properties.Resources.SaveConfigurationChanges);
508-
IList<DataStorage> savedConfigurations = GetSavedConfigurations(m_jsonSchema);
509-
int savedConfigurationCount = savedConfigurations.Count<DataStorage>();
510-
int savedConfigurationIndex = 0;
511-
foreach (IFCExportConfiguration configuration in setupsToSave)
517+
DataStorage configStorage;
518+
if (savedConfigurationIndex >= savedConfigurationCount)
512519
{
513-
DataStorage configStorage;
514-
if (savedConfigurationIndex >= savedConfigurationCount)
515-
{
516-
configStorage = DataStorage.Create(IFCCommandOverrideApplication.TheDocument);
517-
}
518-
else
519-
{
520-
configStorage = savedConfigurations[savedConfigurationIndex];
521-
savedConfigurationIndex++;
522-
}
523-
524-
Entity mapEntity = new Entity(m_jsonSchema);
525-
string configData = configuration.SerializeConfigToJson();
526-
mapEntity.Set<string>(s_configMapField, configData);
527-
configStorage.SetEntity(mapEntity);
520+
configStorage = DataStorage.Create(IFCCommandOverrideApplication.TheDocument);
528521
}
529-
530-
List<ElementId> elementsToDelete = new List<ElementId>();
531-
for (; savedConfigurationIndex < savedConfigurationCount; savedConfigurationIndex++)
522+
else
532523
{
533-
DataStorage configStorage = savedConfigurations[savedConfigurationIndex];
534-
elementsToDelete.Add(configStorage.Id);
524+
configStorage = savedConfigurations[savedConfigurationIndex];
525+
savedConfigurationIndex++;
535526
}
536-
if (elementsToDelete.Count > 0)
537-
IFCCommandOverrideApplication.TheDocument.Delete(elementsToDelete);
538-
539-
transaction.Commit();
527+
528+
Entity mapEntity = new Entity(m_jsonSchema);
529+
string configData = configuration.SerializeConfigToJson();
530+
mapEntity.Set<string>(s_configMapField, configData);
531+
configStorage.SetEntity(mapEntity);
540532
}
541-
catch (System.Exception)
533+
534+
List<ElementId> elementsToDelete = new List<ElementId>();
535+
for (; savedConfigurationIndex < savedConfigurationCount; savedConfigurationIndex++)
542536
{
543-
if (transaction.HasStarted())
544-
transaction.RollBack();
537+
DataStorage configStorage = savedConfigurations[savedConfigurationIndex];
538+
elementsToDelete.Add(configStorage.Id);
545539
}
540+
if (elementsToDelete.Count > 0)
541+
IFCCommandOverrideApplication.TheDocument.Delete(elementsToDelete);
542+
543+
transaction.Commit();
544+
}
545+
catch (System.Exception)
546+
{
547+
if (transaction.HasStarted())
548+
transaction.RollBack();
546549
}
547550
}
548551

0 commit comments

Comments
 (0)