Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/editors/space_node/node_edit.c')
-rw-r--r--source/blender/editors/space_node/node_edit.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/source/blender/editors/space_node/node_edit.c b/source/blender/editors/space_node/node_edit.c
index 9dc39b1839b..3cb5fd94ea9 100644
--- a/source/blender/editors/space_node/node_edit.c
+++ b/source/blender/editors/space_node/node_edit.c
@@ -397,6 +397,14 @@ void ED_node_shader_default(const bContext *C, ID *id)
Material *ma = (Material *)id;
ma->nodetree = ntree;
+ if (BKE_scene_uses_blender_eevee(scene)) {
+ out = nodeAddStaticNode(C, ntree, SH_NODE_OUTPUT_METALLIC);
+ out->locx = 300.0f; out->locy = 300.0f;
+ nodeSetActive(ntree, out);
+ ntreeUpdateTree(CTX_data_main(C), ntree);
+ return;
+ }
+
if (BKE_scene_use_new_shading_nodes(scene)) {
output_type = SH_NODE_OUTPUT_MATERIAL;
shader_type = SH_NODE_BSDF_DIFFUSE;