Add option for door glazing material

This commit is contained in:
Dion Moult
2025-02-13 19:18:17 +11:00
parent 39a30f2577
commit 2d54a48f8e
3 changed files with 6 additions and 0 deletions
@@ -94,6 +94,7 @@ def update_door_modifier_representation(obj: bpy.types.Object) -> None:
if fallback_material := (int(props.lining_material) or int(props.panel_material)):
lining_material = tool.Ifc.get().by_id(int(props.lining_material) or fallback_material)
panel_material = tool.Ifc.get().by_id(int(props.panel_material) or fallback_material)
glazing_material = tool.Ifc.get().by_id(int(props.glazing_material) or fallback_material)
should_create_new_material_set = False
if material := ifcopenshell.util.element.get_material(element):
if (
@@ -122,6 +123,7 @@ def update_door_modifier_representation(obj: bpy.types.Object) -> None:
styles = {
"Lining": ifcopenshell.util.representation.get_material_style(lining_material, body),
"Framing": ifcopenshell.util.representation.get_material_style(panel_material, body),
"Glazing": ifcopenshell.util.representation.get_material_style(glazing_material, body),
}
for item in model_representation.Items:
if aspect := ifcopenshell.util.representation.get_item_shape_aspect(model_representation, item):