Loading shapes now uses the selected geometry library

This commit is contained in:
Dion Moult
2024-10-08 12:16:56 +11:00
parent f66d1bed73
commit 6fb4ce202e
+2 -1
View File
@@ -717,9 +717,10 @@ class Loader(bonsai.core.tool.Loader):
cls, element: ifcopenshell.entity_instance, is_gross: bool = False
) -> Union[ifcopenshell.geom.ShapeElementType, None]:
context_settings = cls.settings.gross_context_settings if is_gross else cls.settings.context_settings
geometry_library = bpy.context.scene.BIMProjectProperties.geometry_library
for settings in context_settings:
try:
result = ifcopenshell.geom.create_shape(settings, element)
result = ifcopenshell.geom.create_shape(settings, element, geometry_library=geometry_library)
if result:
return result
except: