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.
This commit is contained in:
2018-07-05 12:44:15 +02:00
parent 5bd57aaa05
commit dbdafe1209
10 changed files with 98 additions and 102 deletions

View File

@@ -20,7 +20,7 @@
import bpy
from bpy.types import Panel
from rna_prop_ui import PropertyPanel
from bpy_extras.node_utils import find_node_input, find_output_node
from bpy_extras.node_utils import find_node_input
class WorldButtonsPanel:
@@ -109,7 +109,7 @@ class EEVEE_WORLD_PT_surface(WorldButtonsPanel, Panel):
if world.use_nodes:
ntree = world.node_tree
node = find_output_node(ntree, ('OUTPUT_WORLD',))
node = ntree.get_output_node('EEVEE')
if node:
input = find_node_input(node, 'Surface')