v0.3.2
Fixes styling of materials pushed into an open Bonsai model, and gives
colour-less materials a colour from a category scheme.
Pushed materials now show their colour
- Styles are actually applied. The add-on passed an
IfcColourRgbentity
where ifcopenshell expects a dict, sostyle.add_surface_stylealways
raised inside a swallowedexceptand no colour was ever applied. - No more invalid styles. The style is now built in one shot; a
mid-way failure could previously leave anIfcSurfaceStylewith
Styles=$(invalid IFC4SET [1:?]), which was then re-used and could
crash ifcopenshell's style loader on the next model open. - Re-used materials get styled too. Materials already present in the
model (found by their materialsdb identity) were never styled when a push
re-used them. Third-party styles are preserved; only ours are refreshed. - Bonsai viewport. Styles added to an already-open model are now
registered as Blender materials (created, linked, coloured) like an
import would, so layer walls display their colours and the style editor
no longer fails on the missing material.
Category colour schemes
- Surface styles keep the producer colour when a material defines one
(color <int>); otherwise they take the colour of their category from a
named scheme — default Lesosai (category <Category>,
material_builder.SCHEMES). IfcColourRgbcomponents are normalised to 0–1 (they were written as
0–255). Construction exports now style their materials as well.
Full changelog: v0.3.1...v0.3.2