IfcGit.load_project() can be used to refresh scene

If no file path is given, clear blender objects and regenerate
the scene from the current ifc project in IfcStore
This commit is contained in:
Bruno Postle
2023-11-19 10:49:58 +00:00
parent 44b625bf24
commit 9483835356
+3 -2
View File
@@ -207,10 +207,11 @@ class IfcGit:
)
@classmethod
def load_project(cls, path_ifc):
def load_project(cls, path_ifc=""):
"""Clear and load an ifc project"""
IfcStore.purge()
if path_ifc:
IfcStore.purge()
# delete any IfcProject/* collections
for collection in bpy.data.collections:
if re.match("^IfcProject/", collection.name):