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:
authorJoshua Leung <aligorith@gmail.com>2018-04-30 15:46:30 +0300
committerJoshua Leung <aligorith@gmail.com>2018-04-30 15:49:07 +0300
commit7714d6dd65f3bce9d188f2c7bdde884fb920a602 (patch)
tree3a645f004dfc0b2e5dc7be3cafc1b350eb76b227 /source/blender/makesrna/intern/rna_material.c
parent36324f9dab07bd3bf969f1d033d059e87865dc0d (diff)
COW Fix: Material property update callbacks need to tag depsgraph for COW updates
Otherwise, trying to change color/material properties of EEVEE materials that have been keyframed doesn't work until a new keyframe has been inserted. NOTE: There's still some wonkiness if you edit more than one keyframed value before keyframing (i.e. the other unkeyed value temporarily gets reset). But that's more of a general COW+animation issue.
Diffstat (limited to 'source/blender/makesrna/intern/rna_material.c')
-rw-r--r--source/blender/makesrna/intern/rna_material.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/makesrna/intern/rna_material.c b/source/blender/makesrna/intern/rna_material.c
index 0621c1e1ad6..7dc76120097 100644
--- a/source/blender/makesrna/intern/rna_material.c
+++ b/source/blender/makesrna/intern/rna_material.c
@@ -90,7 +90,7 @@ static void rna_Material_update(Main *UNUSED(bmain), Scene *UNUSED(scene), Point
{
Material *ma = ptr->id.data;
- DEG_id_tag_update(&ma->id, 0);
+ DEG_id_tag_update(&ma->id, DEG_TAG_COPY_ON_WRITE);
WM_main_add_notifier(NC_MATERIAL | ND_SHADING, ma);
}
@@ -108,7 +108,7 @@ static void rna_Material_draw_update(Main *UNUSED(bmain), Scene *UNUSED(scene),
{
Material *ma = ptr->id.data;
- DEG_id_tag_update(&ma->id, 0);
+ DEG_id_tag_update(&ma->id, DEG_TAG_COPY_ON_WRITE);
WM_main_add_notifier(NC_MATERIAL | ND_SHADING_DRAW, ma);
}