mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-13 02:47:48 +00:00
Handle materials which don't have nodes
This commit is contained in:
@@ -919,7 +919,8 @@ class IfcExporter():
|
||||
return self.file.create_entity('IfcSurfaceStyleRendering', **rendering_attributes)
|
||||
|
||||
def get_rendering_attributes(self, material):
|
||||
if 'Principled BSDF' not in material.node_tree.nodes:
|
||||
if not hasattr(material.node_tree, 'nodes') \
|
||||
or 'Principled BSDF' not in material.node_tree.nodes:
|
||||
return {}
|
||||
bsdf = material.node_tree.nodes['Principled BSDF']
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user