diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2015-05-26 14:15:01 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2015-05-26 14:15:34 +0300 |
commit | 7487a4d4ac0e95f666e309b89898d3e9838a8ee6 (patch) | |
tree | 334750067e7e3a6da8d64b021794e850ab53fa05 /intern/cycles/blender/addon/ui.py | |
parent | d20fd2da72d9e1fbdba4306903899e5432bd4775 (diff) |
Fix T44763: Surface Panel does not update correctly according to Node Output for Cycles UI
Diffstat (limited to 'intern/cycles/blender/addon/ui.py')
-rw-r--r-- | intern/cycles/blender/addon/ui.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/intern/cycles/blender/addon/ui.py b/intern/cycles/blender/addon/ui.py index 430c0a964b1..7fa71397271 100644 --- a/intern/cycles/blender/addon/ui.py +++ b/intern/cycles/blender/addon/ui.py @@ -733,9 +733,14 @@ def find_node(material, nodetype): if material and material.node_tree: ntree = material.node_tree + active_output_node = None for node in ntree.nodes: if getattr(node, "type", None) == nodetype: - return node + if getattr(node, "is_active_output", True): + return node + if not active_output_node: + active_output_node = node + return active_output_node return None |