diff --git a/src/blenderbim/Makefile b/src/blenderbim/Makefile index 5e9ee0a24c..9f2dc966e6 100644 --- a/src/blenderbim/Makefile +++ b/src/blenderbim/Makefile @@ -3,9 +3,11 @@ PYVERSION:=py37 ifeq ($(PYVERSION), py37) PYLIBDIR:=python3.7 +PYNUMBER:=37 endif ifeq ($(PYVERSION), py39) PYLIBDIR:=python3.9 +PYNUMBER:=39 endif ifeq ($(PLATFORM), linux) @@ -67,12 +69,7 @@ endif cp -r blenderbim/* dist/blenderbim/ # Provides IfcOpenShell Python functionality -ifeq ($(PYVERSION), py37) - cd dist/working && wget https://s3.amazonaws.com/ifcopenshell-builds/ifcblender-python-37-v0.6.0-f14d349-$(PLATFORM)64.zip -endif -ifeq ($(PYVERSION), py39) - cd dist/working && wget https://s3.amazonaws.com/ifcopenshell-builds/ifcblender-python-39-v0.6.0-f14d349-$(PLATFORM)64.zip -endif + cd dist/working && wget https://s3.amazonaws.com/ifcopenshell-builds/ifcblender-python-$(PYNUMBER)-v0.6.0-0087fa8-$(PLATFORM)64.zip cd dist/working && unzip ifcblender* cp -r dist/working/io_import_scene_ifc/ifcopenshell dist/blenderbim/libs/site/packages/ diff --git a/src/ifcclash/ifcclash/collider.py b/src/ifcclash/ifcclash/collider.py index 472fb9416d..de360da1ce 100644 --- a/src/ifcclash/ifcclash/collider.py +++ b/src/ifcclash/ifcclash/collider.py @@ -31,23 +31,14 @@ class Collider: self.groups[name] = {"elements": {}, "objects": {}} def create_objects(self, name, ifc_file, iterator, elements): - self.tree.add_iterator(iterator) - self.groups[name]["elements"].update({e.GlobalId: e for e in elements}) - - # Temporary hack. See #1357. - import multiprocessing - - iterator = ifcopenshell.geom.iterator( - ifcopenshell.geom.settings(), ifc_file, multiprocessing.cpu_count(), include=elements - ) - valid_file = iterator.initialize() - if not valid_file: - return False + assert iterator.initialize() while True: + self.tree.add_element(iterator.get_native()) shape = iterator.get() self.create_object(name, shape.guid, shape) if not iterator.next(): break + self.groups[name]["elements"].update({e.GlobalId: e for e in elements}) def create_object(self, group_name, id, shape): obj = hppfcl.CollisionObject( diff --git a/src/ifcclash/ifcclash/ifcclash.py b/src/ifcclash/ifcclash/ifcclash.py index e1f828d709..172b09122a 100644 --- a/src/ifcclash/ifcclash/ifcclash.py +++ b/src/ifcclash/ifcclash/ifcclash.py @@ -34,7 +34,7 @@ from . import collider class Clasher: def __init__(self, settings): self.settings = settings - self.geom_settings = ifcopenshell.geom.settings(DISABLE_TRIANGULATION=True) + self.geom_settings = ifcopenshell.geom.settings() self.clash_sets = [] self.collider = collider.Collider() self.selector = ifcopenshell.util.selector.Selector()