diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2022-04-19 10:57:45 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2022-04-19 13:09:18 +0300 |
commit | 1e3f4c70ab56578b8b0e0056870bd17cc118982a (patch) | |
tree | 3656653a343b807ef2ed308f604b02dad5e1a5b5 /source/blender | |
parent | c2c17cc076a4ade5da7b396d7b3d3155cc9c5a84 (diff) |
Material: Add name to default shaders
Improve debugging experience.
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/blenkernel/intern/material.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/material.c b/source/blender/blenkernel/intern/material.c index 4caaf314888..002b496393f 100644 --- a/source/blender/blenkernel/intern/material.c +++ b/source/blender/blenkernel/intern/material.c @@ -1943,6 +1943,8 @@ static void material_default_gpencil_init(Material *ma) static void material_default_surface_init(Material *ma) { + strcpy(ma->id.name, "MADefault Surface"); + bNodeTree *ntree = ntreeAddTree(NULL, "Shader Nodetree", ntreeType_Shader->idname); ma->nodetree = ntree; ma->use_nodes = true; @@ -1969,6 +1971,8 @@ static void material_default_surface_init(Material *ma) static void material_default_volume_init(Material *ma) { + strcpy(ma->id.name, "MADefault Volume"); + bNodeTree *ntree = ntreeAddTree(NULL, "Shader Nodetree", ntreeType_Shader->idname); ma->nodetree = ntree; ma->use_nodes = true; @@ -1992,6 +1996,8 @@ static void material_default_volume_init(Material *ma) static void material_default_holdout_init(Material *ma) { + strcpy(ma->id.name, "MADefault Holdout"); + bNodeTree *ntree = ntreeAddTree(NULL, "Shader Nodetree", ntreeType_Shader->idname); ma->nodetree = ntree; ma->use_nodes = true; |