diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-07-05 13:44:15 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-07-05 19:43:48 +0300 |
commit | dbdafe1209a4787d6f8dcafa034bc9ced3c7f365 (patch) | |
tree | b9457d3f0c2c8e54de05dbc594d0e8caa4f514e0 /release/scripts/startup/bl_ui/properties_material.py | |
parent | 5bd57aaa052d9578d089a92338d6f0977b5d6c5c (diff) |
Shaders: add target setting to material output node.
This makes it possible to have a single shading nodetree that contains
separate Cycles and Eevee shaders. By default the target is set to All
so shaders are shared.
Diffstat (limited to 'release/scripts/startup/bl_ui/properties_material.py')
-rw-r--r-- | release/scripts/startup/bl_ui/properties_material.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/release/scripts/startup/bl_ui/properties_material.py b/release/scripts/startup/bl_ui/properties_material.py index fdbf0b240c4..3761cbba372 100644 --- a/release/scripts/startup/bl_ui/properties_material.py +++ b/release/scripts/startup/bl_ui/properties_material.py @@ -21,7 +21,7 @@ import bpy from bpy.types import Menu, Panel, UIList from rna_prop_ui import PropertyPanel from bpy.app.translations import pgettext_iface as iface_ -from bpy_extras.node_utils import find_node_input, find_output_node +from bpy_extras.node_utils import find_node_input class MATERIAL_MT_specials(Menu): @@ -140,7 +140,7 @@ class EEVEE_MATERIAL_PT_context_material(MaterialButtonsPanel, Panel): def panel_node_draw(layout, ntree, output_type): - node = find_output_node(ntree, output_type) + node = ntree.get_output_node('EEVEE') if node: input = find_node_input(node, 'Surface') @@ -171,7 +171,7 @@ class EEVEE_MATERIAL_PT_surface(MaterialButtonsPanel, Panel): layout.separator() if mat.use_nodes: - panel_node_draw(layout, mat.node_tree, ('OUTPUT_EEVEE_MATERIAL', 'OUTPUT_MATERIAL')) + panel_node_draw(layout, mat.node_tree, 'OUTPUT_MATERIAL') else: layout.use_property_split = True layout.prop(mat, "diffuse_color", text="Base Color") |