New feature to select all objects in same container

This commit is contained in:
Dion Moult
2021-11-07 17:02:05 +11:00
parent 05068754b9
commit 61e510e45c
9 changed files with 71 additions and 0 deletions
@@ -60,6 +60,10 @@ class Spatial(blenderbim.core.tool.Spatial):
def get_container(cls, element):
return ifcopenshell.util.element.get_container(element)
@classmethod
def get_decomposed_elements(cls, container):
return ifcopenshell.util.element.get_decomposition(container)
@classmethod
def get_object_matrix(cls, obj):
return obj.matrix_world
@@ -101,6 +105,10 @@ class Spatial(blenderbim.core.tool.Spatial):
tool.Ifc, tool.Collector, tool.Spatial, structure_obj=structure_obj, element_obj=element_obj
)
@classmethod
def select_object(cls, obj):
obj.select_set(True)
@classmethod
def set_active_object(cls, obj):
bpy.context.view_layer.objects.active = obj