Update all geom settings to new v0.8 syntax

This commit is contained in:
Dion Moult
2024-06-09 16:15:55 +10:00
parent 52f9db4522
commit cdce612566
17 changed files with 37 additions and 40 deletions
@@ -186,7 +186,7 @@ class Patcher:
# This fixes symptom C.
settings = ifcopenshell.geom.settings()
settings.set(settings.INCLUDE_CURVES, True)
settings.set("dimensionality", ifcopenshell.ifcopenshell_wrapper.CURVES_SURFACES_AND_SOLIDS)
unit_scale = ifcopenshell.util.unit.calculate_unit_scale(self.file)
for curve in self.file.by_type("IfcIndexedPolyCurve"):
if True in [s.is_a("IfcArcIndex") for s in curve.Segments]:
+1 -1
View File
@@ -194,7 +194,7 @@ class Patcher:
if c.ContextType == "Model"
]
)
self.settings.set_context_ids(self.body_contexts)
self.settings.set("context-ids", self.body_contexts)
products = self.elements
iterator = ifcopenshell.geom.iterator(self.settings, self.file, multiprocessing.cpu_count(), include=products)
@@ -71,7 +71,7 @@ class Patcher:
return
settings = ifcopenshell.geom.settings()
settings.set_context_ids([context.id()])
settings.set("context-ids", [context.id()])
iterator = ifcopenshell.geom.iterator(settings, self.file, multiprocessing.cpu_count(), include=elements)
replacements = {}
if iterator.initialize():