From a30c82d2d2d1735431e1cca478014b3bd4e6136b Mon Sep 17 00:00:00 2001 From: babio Date: Fri, 28 Jul 2023 06:08:26 -0700 Subject: [PATCH] 23_3_1 update --- .../Autodesk.SteelConnections.ASIFC.dll | Bin 196432 -> 196432 bytes .../DefaultUserDefinedParameterSets.txt | 4 ++ .../Resources/ADSKIFCExporterHelp.htm | 20 +++++++ .../bundle/PackageContents.xml | 6 +- Install/RevitIFCSetupWix/Product.wxs | 2 +- .../RevitIFCSetupWix/RevitIFCSetupWix.wixproj | 2 +- Install/RevitIFCSetupWix/buildInstaller.bat | 8 +-- .../Properties/AssemblyInfo.cs | 4 +- .../Properties/AssemblyInfo.cs | 4 +- .../Utility/IfcSchemaEntityTree.cs | 20 +++++++ .../Exporter/HostedSweepExporter.cs | 2 +- .../Exporter/WallSweepExporter.cs | 2 +- .../Properties/AssemblyInfo.cs | 4 +- .../Revit.IFC.Export/Utility/OpeningUtil.cs | 55 ++++++++++++++---- .../Properties/AssemblyInfo.cs | 4 +- .../Properties/AssemblyInfo.cs | 4 +- 16 files changed, 109 insertions(+), 32 deletions(-) diff --git a/Install/Program Files to Install/Autodesk.SteelConnections.ASIFC.dll b/Install/Program Files to Install/Autodesk.SteelConnections.ASIFC.dll index 9fcd7ba501b97b266306375a70da34964d853494..1140d33eaa0415a971ae02f969e12bdd4e76b83f 100644 GIT binary patch delta 1595 zcmV-B2E_T${tM9l3y_Ed)4{@#i%kLyvw_;R+5w>00RfkL*#Rd30k@;s0olb63Dd84 zwZ!p3mI6oKOg=PBw~U_xBQF6nm$1$PH3c&;E;uxo>dpdE1Jl96mp{(}84&1S3(r-U zvqF|is<_ggVF9;j&jKU^3se9e0096O08{`Tx0liaGXV)R05AY905||Nm($Y%vjH== zhtvXB0SPkzFaRz9H~=)a=hXrv1Qb372`Yw2hW8Bt2LhmiB`+|7B`cR7+5%D_F1o=D z4{w3koRae#^njpHyZ7u&Mbb*mX^PE{c0iB+w~^WcBMt?XFoG75x4Gy73;};yStb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O@IIzvLGz-?oyDo+mO4f$tf#FuQ2_U2^o1EQvd(}003~Y#aaLW diff --git a/Install/Program Files to Install/DefaultUserDefinedParameterSets.txt b/Install/Program Files to Install/DefaultUserDefinedParameterSets.txt index bb46a284..39eab060 100644 --- a/Install/Program Files to Install/DefaultUserDefinedParameterSets.txt +++ b/Install/Program Files to Install/DefaultUserDefinedParameterSets.txt @@ -14,6 +14,10 @@ # Pressure, Ratio, Real, Text, ThermalTransmittance, ThermodynamicTemperature, Volume, # VolumetricFlowRate # +# Since 23.3.0, type properties are not exported in case they are not specified in the user-defined property sets file. +# To export type properties for the IFCElement, for example, +# a user should include "IFCElementType" in the proper .txt file. +# # Example property set definition for COBie: # #PropertySet: COBie_Specification T IfcElementType diff --git a/Install/Program Files to Install/bundle/Contents/Resources/ADSKIFCExporterHelp.htm b/Install/Program Files to Install/bundle/Contents/Resources/ADSKIFCExporterHelp.htm index a5bb7400..65bb79f1 100644 --- a/Install/Program Files to Install/bundle/Contents/Resources/ADSKIFCExporterHelp.htm +++ b/Install/Program Files to Install/bundle/Contents/Resources/ADSKIFCExporterHelp.htm @@ -237,6 +237,26 @@

Support Information

Version History

+
23.3.1.0
+

+ General: +

    +
  • This is the first version of IFC Exporter for Revit 2023. +
  • It contains a various improvements and bug fixes for the basic Revit 2023. +
+

+
+

+ Bug Fixes: +

    +
  • Fixed bug with "Ifc Export As" cannot be opened. +
  • Fix sketch-based openings in sloped slabs. +
  • Fixed placement of some specific wall sweep elements. +
+

+
+
+
23.3.0.0

General: diff --git a/Install/Program Files to Install/bundle/PackageContents.xml b/Install/Program Files to Install/bundle/PackageContents.xml index cb5809f6..4b42d8a6 100644 --- a/Install/Program Files to Install/bundle/PackageContents.xml +++ b/Install/Program Files to Install/bundle/PackageContents.xml @@ -1,10 +1,10 @@  - + - - + + \ No newline at end of file diff --git a/Install/RevitIFCSetupWix/Product.wxs b/Install/RevitIFCSetupWix/Product.wxs index de01d216..f9300b85 100644 --- a/Install/RevitIFCSetupWix/Product.wxs +++ b/Install/RevitIFCSetupWix/Product.wxs @@ -2,7 +2,7 @@ - + diff --git a/Install/RevitIFCSetupWix/RevitIFCSetupWix.wixproj b/Install/RevitIFCSetupWix/RevitIFCSetupWix.wixproj index b876fb35..33c91918 100644 --- a/Install/RevitIFCSetupWix/RevitIFCSetupWix.wixproj +++ b/Install/RevitIFCSetupWix/RevitIFCSetupWix.wixproj @@ -6,7 +6,7 @@ 3.8 7dfbd495-c588-4c7b-b8f6-5b793adb06f2 2.0 - IFC for Revit 2023.3.0.0 + IFC for Revit 2023.3.1.0 Package $(MSBuildExtensionsPath32)\Microsoft\WiX\v3.x\Wix.targets $(MSBuildExtensionsPath)\Microsoft\WiX\v3.x\Wix.targets diff --git a/Install/RevitIFCSetupWix/buildInstaller.bat b/Install/RevitIFCSetupWix/buildInstaller.bat index 14305d11..592c5a49 100644 --- a/Install/RevitIFCSetupWix/buildInstaller.bat +++ b/Install/RevitIFCSetupWix/buildInstaller.bat @@ -11,9 +11,9 @@ rem It is necessary to add the Wix bin directory to the system path temporarily SET PATH=%PATH%;%WixRoot% candle.exe -dProjectDir=%2 -ext WixUtilExtension %2Product.wxs -light.exe -ext WixUtilExtension -out RevitIFC2023.3.0.msi product.wixobj -ext WixUIExtension +light.exe -ext WixUtilExtension -out RevitIFC2023.3.1.msi product.wixobj -ext WixUIExtension -copy RevitIFC2023.3.0.msi %1..\Releasex64 -del RevitIFC2023.3.0.msi +copy RevitIFC2023.3.1.msi %1..\Releasex64 +del RevitIFC2023.3.1.msi -echo %1..\Releasex64\RevitIFC2023.3.0.msi +echo %1..\Releasex64\RevitIFC2023.3.1.msi diff --git a/Source/IFCExporterUIOverride/Properties/AssemblyInfo.cs b/Source/IFCExporterUIOverride/Properties/AssemblyInfo.cs index 1deae71d..984f1caf 100644 --- a/Source/IFCExporterUIOverride/Properties/AssemblyInfo.cs +++ b/Source/IFCExporterUIOverride/Properties/AssemblyInfo.cs @@ -66,6 +66,6 @@ // The following information is used in the Open Source version as the release version number. // The number will show up in the Title bar of the export dialog as well as at the IFC header file // This number must be manually updated prior to releasing the new version -[assembly: AssemblyVersion("23.3.0.0")] -[assembly: AssemblyFileVersion("23.3.0.0")] +[assembly: AssemblyVersion("23.3.1.0")] +[assembly: AssemblyFileVersion("23.3.1.0")] #endif \ No newline at end of file diff --git a/Source/Revit.IFC.Common/Properties/AssemblyInfo.cs b/Source/Revit.IFC.Common/Properties/AssemblyInfo.cs index 9722b65b..a34952c5 100644 --- a/Source/Revit.IFC.Common/Properties/AssemblyInfo.cs +++ b/Source/Revit.IFC.Common/Properties/AssemblyInfo.cs @@ -13,8 +13,8 @@ [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] -[assembly: AssemblyVersion("23.3.0.0")] -[assembly: AssemblyFileVersion("23.3.0.0")] +[assembly: AssemblyVersion("23.3.1.0")] +[assembly: AssemblyFileVersion("23.3.1.0")] #endif diff --git a/Source/Revit.IFC.Common/Utility/IfcSchemaEntityTree.cs b/Source/Revit.IFC.Common/Utility/IfcSchemaEntityTree.cs index a8291ffc..afb8e932 100644 --- a/Source/Revit.IFC.Common/Utility/IfcSchemaEntityTree.cs +++ b/Source/Revit.IFC.Common/Utility/IfcSchemaEntityTree.cs @@ -252,6 +252,26 @@ static public IfcSchemaEntityTree GetEntityDictFor(IFCVersion ifcFileVersion) return GetEntityDictFor(schemaFile); } + ///

+ /// Get the IFC Entity Dictionary for the given IFC version specified by the schema file name (without extension) + /// + /// the IFC schema file name (without extension). Caller must make sure it is the supported schema file + /// the tree, or null if the schema file is not found + static public IfcSchemaEntityTree GetEntityDictFor(string schemaFile) + { + if (m_IFCSchemaDict.ContainsKey(schemaFile)) + return m_IFCSchemaDict[schemaFile]; + + // if not found, process the file and add into the static dictionary + IfcSchemaEntityTree entityTree = PopulateEntityDictFor(schemaFile); + if (entityTree == null) + return null; + + m_IFCSchemaDict.Add(schemaFile, entityTree); + m_IFCEntityPredefTypeDict.Add(schemaFile, entityTree.PredefinedTypeEnumDict); + return entityTree; + } + /// /// Get the IFC Entity Dictionary for the given IFC version specified by the schema file name (without extension) /// diff --git a/Source/Revit.IFC.Export/Exporter/HostedSweepExporter.cs b/Source/Revit.IFC.Export/Exporter/HostedSweepExporter.cs index 32fdc46e..5aed8a29 100644 --- a/Source/Revit.IFC.Export/Exporter/HostedSweepExporter.cs +++ b/Source/Revit.IFC.Export/Exporter/HostedSweepExporter.cs @@ -46,7 +46,7 @@ public static void Export(ExporterIFC exporterIFC, HostedSweep hostedSweep, Geom if (catId == new ElementId(BuiltInCategory.OST_Gutter)) ExportGutter(exporterIFC, hostedSweep, geometryElement, productWrapper); else - ProxyElementExporter.Export(exporterIFC, hostedSweep, geometryElement, productWrapper); + GenericElementExporter.ExportElement(exporterIFC, hostedSweep, geometryElement, productWrapper); } /// diff --git a/Source/Revit.IFC.Export/Exporter/WallSweepExporter.cs b/Source/Revit.IFC.Export/Exporter/WallSweepExporter.cs index e443ec73..4f5ef559 100644 --- a/Source/Revit.IFC.Export/Exporter/WallSweepExporter.cs +++ b/Source/Revit.IFC.Export/Exporter/WallSweepExporter.cs @@ -46,7 +46,7 @@ public static void Export(ExporterIFC exporterIFC, WallSweep wallSweep, Geometry if (wallSweepInfo.WallSweepType == WallSweepType.Reveal) return; - if (!ProxyElementExporter.Export(exporterIFC, wallSweep, geometryElement, productWrapper)) + if (!GenericElementExporter.ExportElement(exporterIFC, wallSweep, geometryElement, productWrapper)) return; HostObjectExporter.ExportHostObjectMaterials(exporterIFC, wallSweep, productWrapper.GetAnElement(), diff --git a/Source/Revit.IFC.Export/Properties/AssemblyInfo.cs b/Source/Revit.IFC.Export/Properties/AssemblyInfo.cs index 4bdaafa6..246419a4 100644 --- a/Source/Revit.IFC.Export/Properties/AssemblyInfo.cs +++ b/Source/Revit.IFC.Export/Properties/AssemblyInfo.cs @@ -14,8 +14,8 @@ [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] -[assembly: AssemblyVersion("23.3.0.0")] -[assembly: AssemblyFileVersion("23.3.0.0")] +[assembly: AssemblyVersion("23.3.1.0")] +[assembly: AssemblyFileVersion("23.3.1.0")] #endif diff --git a/Source/Revit.IFC.Export/Utility/OpeningUtil.cs b/Source/Revit.IFC.Export/Utility/OpeningUtil.cs index 7bb090c7..92754ab7 100644 --- a/Source/Revit.IFC.Export/Utility/OpeningUtil.cs +++ b/Source/Revit.IFC.Export/Utility/OpeningUtil.cs @@ -485,24 +485,19 @@ static public IFCAnyHandle CreateOpening(ExporterIFC exporterIFC, IFCAnyHandle h lcs = GeometryUtil.CreateTransformFromPlane(curveLoops[0].GetPlane()); } - ElementId catId = CategoryUtil.GetSafeCategoryId(insertElement); - if (extrusionData.ScaledExtrusionLength < MathUtil.Eps()) { - double thickness = 0.0; - if (hostElement is Floor) - ParameterUtil.GetDoubleValueFromElement(hostElement, BuiltInParameter.FLOOR_ATTR_THICKNESS_PARAM, out thickness); - else if (hostElement is RoofBase) - ParameterUtil.GetDoubleValueFromElement(hostElement, BuiltInParameter.ROOF_ATTR_THICKNESS_PARAM, out thickness); - else if (hostElement is Ceiling) - ParameterUtil.GetDoubleValueFromElement(hostElement, BuiltInParameter.CEILING_THICKNESS, out thickness); + double extrusionLength = 0.0; + if (hostElement is Floor || hostElement is RoofBase || hostElement is Ceiling) + extrusionLength = CalculateOpeningExtrusionInFloorRoofOrCeiling(hostElement, extrusionData); - if (thickness < MathUtil.Eps()) + if (extrusionLength < MathUtil.Eps()) return null; - extrusionData.ScaledExtrusionLength = UnitUtil.ScaleLength(thickness); + extrusionData.ScaledExtrusionLength = UnitUtil.ScaleLength(extrusionLength); } + ElementId catId = CategoryUtil.GetSafeCategoryId(insertElement); IFCAnyHandle openingHnd = null; IFCAnyHandle openingProdRepHnd = RepresentationUtil.CreateExtrudedProductDefShape(exporterIFC, insertElement, catId, curveLoops, lcs, extrusionData.ExtrusionDirection, extrusionData.ScaledExtrusionLength); @@ -596,5 +591,43 @@ static bool GetOpeningDirections(Element hostElem, out XYZ perpToWall, out XYZ w return isLinearWall; } + + /// + /// Calculates extrusion length for openings in floor roof or ceiling based on the element thickness for not sloped elements, + /// and based on bounding box for sloped. Also defines the extrusion direction for sloped elements. + /// + /// The host element. + /// The opening extrusion data + /// The extrusion length + private static double CalculateOpeningExtrusionInFloorRoofOrCeiling(Element hostElement, IFCExtrusionData extrusionData) + { + double extrusionLength = 0.0; + //Use the element thickness for not sloped elements, if the host element is sloped, the extrusions of the resulting opening will not intersect the host element. + //To handle such cases using bounding box height instead of thickness. + // + double slopeValue = 0.0; + ParameterUtil.GetDoubleValueFromElement(hostElement, BuiltInParameter.ROOF_SLOPE, out slopeValue); + if (MathUtil.IsAlmostZero(slopeValue)) + { + if (hostElement is Floor) + ParameterUtil.GetDoubleValueFromElement(hostElement, BuiltInParameter.FLOOR_ATTR_THICKNESS_PARAM, out extrusionLength); + else if (hostElement is RoofBase) + ParameterUtil.GetDoubleValueFromElement(hostElement, BuiltInParameter.ROOF_ATTR_THICKNESS_PARAM, out extrusionLength); + else if (hostElement is Ceiling) + ParameterUtil.GetDoubleValueFromElement(hostElement, BuiltInParameter.CEILING_THICKNESS, out extrusionLength); + } + else + { + BoundingBoxXYZ hostElementBoundingBox = hostElement.get_BoundingBox(hostElement.Document.GetElement(hostElement.OwnerViewId) as View); + extrusionLength = hostElementBoundingBox.Max.Z - hostElementBoundingBox.Min.Z; + + //Need to recheck the ExtrusionDirection. + //If slope is positive value the host it will be above. + // + extrusionData.ExtrusionDirection = (slopeValue > 0) ? XYZ.BasisZ : -XYZ.BasisZ; + } + + return extrusionLength; + } } } \ No newline at end of file diff --git a/Source/Revit.IFC.Import.Core/Properties/AssemblyInfo.cs b/Source/Revit.IFC.Import.Core/Properties/AssemblyInfo.cs index 22bc1147..81f5bfdd 100644 --- a/Source/Revit.IFC.Import.Core/Properties/AssemblyInfo.cs +++ b/Source/Revit.IFC.Import.Core/Properties/AssemblyInfo.cs @@ -13,8 +13,8 @@ [assembly: AssemblyDescription("Revit.IFC.Import.Core")] [assembly: AssemblyCompany("Autodesk")] [assembly: AssemblyCopyright("@2012-2023 Autodesk, Inc. All rights reserved.")] -[assembly: AssemblyVersion("23.3.0.0")] -[assembly: AssemblyFileVersion("23.3.0.0")] +[assembly: AssemblyVersion("23.3.1.0")] +[assembly: AssemblyFileVersion("23.3.1.0")] // Version information can now be found in Source\Foundation\RevitENU\Version.cs // diff --git a/Source/Revit.IFC.Import/Properties/AssemblyInfo.cs b/Source/Revit.IFC.Import/Properties/AssemblyInfo.cs index 9426e312..13aba152 100644 --- a/Source/Revit.IFC.Import/Properties/AssemblyInfo.cs +++ b/Source/Revit.IFC.Import/Properties/AssemblyInfo.cs @@ -12,8 +12,8 @@ [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] -[assembly: AssemblyVersion("23.3.0.0")] -[assembly: AssemblyFileVersion("23.3.0.0")] +[assembly: AssemblyVersion("23.3.1.0")] +[assembly: AssemblyFileVersion("23.3.1.0")] #endif #region Using directives