diff options
-rw-r--r-- | source/blender/modifiers/intern/MOD_array.c | 1 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_datatransfer.c | 5 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_displace.c | 1 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_mask.c | 1 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_normal_edit.c | 1 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_screw.c | 1 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_simpledeform.c | 1 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_uvproject.c | 8 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_uvwarp.c | 2 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_warp.c | 1 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_wave.c | 3 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_weightvgedit.c | 3 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_weightvgmix.c | 4 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_weightvgproximity.c | 6 |
14 files changed, 30 insertions, 8 deletions
diff --git a/source/blender/modifiers/intern/MOD_array.c b/source/blender/modifiers/intern/MOD_array.c index cd2f7cc364b..9decf8e3bb5 100644 --- a/source/blender/modifiers/intern/MOD_array.c +++ b/source/blender/modifiers/intern/MOD_array.c @@ -107,6 +107,7 @@ static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphConte if (amd->offset_ob != NULL) { DEG_add_object_relation(ctx->node, amd->offset_ob, DEG_OB_COMP_TRANSFORM, "Array Modifier Offset"); } + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "Array Modifier"); } BLI_INLINE float sum_v3(const float v[3]) diff --git a/source/blender/modifiers/intern/MOD_datatransfer.c b/source/blender/modifiers/intern/MOD_datatransfer.c index d3f573ec4b6..d3c0dd783cc 100644 --- a/source/blender/modifiers/intern/MOD_datatransfer.c +++ b/source/blender/modifiers/intern/MOD_datatransfer.c @@ -132,6 +132,11 @@ static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphConte CustomDataMask mask = BKE_object_data_transfer_dttypes_to_cdmask(dtmd->data_types); DEG_add_object_relation_with_customdata(ctx->node, dtmd->ob_source, DEG_OB_COMP_GEOMETRY, mask, "DataTransfer Modifier"); + + if (dtmd->flags & MOD_DATATRANSFER_OBSRC_TRANSFORM) { + DEG_add_object_relation(ctx->node, dtmd->ob_source, DEG_OB_COMP_TRANSFORM, "DataTransfer Modifier"); + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "DataTransfer Modifier"); + } } } diff --git a/source/blender/modifiers/intern/MOD_displace.c b/source/blender/modifiers/intern/MOD_displace.c index 082c8f9c589..a477191357e 100644 --- a/source/blender/modifiers/intern/MOD_displace.c +++ b/source/blender/modifiers/intern/MOD_displace.c @@ -148,6 +148,7 @@ static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphConte { DisplaceModifierData *dmd = (DisplaceModifierData *)md; if (dmd->map_object != NULL && dmd->texmapping == MOD_DISP_MAP_OBJECT) { + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "Displace Modifier"); DEG_add_object_relation(ctx->node, dmd->map_object, DEG_OB_COMP_TRANSFORM, "Displace Modifier"); } if (dmd->texmapping == MOD_DISP_MAP_GLOBAL || diff --git a/source/blender/modifiers/intern/MOD_mask.c b/source/blender/modifiers/intern/MOD_mask.c index 1a8027e6697..7c43545a3d3 100644 --- a/source/blender/modifiers/intern/MOD_mask.c +++ b/source/blender/modifiers/intern/MOD_mask.c @@ -81,6 +81,7 @@ static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphConte /* TODO(sergey): Is it a proper relation here? */ DEG_add_object_relation(ctx->node, mmd->ob_arm, DEG_OB_COMP_TRANSFORM, "Mask Modifier"); arm->flag |= ARM_HAS_VIZ_DEPS; + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "Mask Modifier"); } } diff --git a/source/blender/modifiers/intern/MOD_normal_edit.c b/source/blender/modifiers/intern/MOD_normal_edit.c index f76acd3983d..d7126113fe8 100644 --- a/source/blender/modifiers/intern/MOD_normal_edit.c +++ b/source/blender/modifiers/intern/MOD_normal_edit.c @@ -536,6 +536,7 @@ static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphConte NormalEditModifierData *enmd = (NormalEditModifierData *) md; if (enmd->target) { DEG_add_object_relation(ctx->node, enmd->target, DEG_OB_COMP_TRANSFORM, "NormalEdit Modifier"); + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "NormalEdit Modifier"); } } diff --git a/source/blender/modifiers/intern/MOD_screw.c b/source/blender/modifiers/intern/MOD_screw.c index c59be8151d4..1de2a976fca 100644 --- a/source/blender/modifiers/intern/MOD_screw.c +++ b/source/blender/modifiers/intern/MOD_screw.c @@ -1116,6 +1116,7 @@ static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphConte ScrewModifierData *ltmd = (ScrewModifierData *)md; if (ltmd->ob_axis != NULL) { DEG_add_object_relation(ctx->node, ltmd->ob_axis, DEG_OB_COMP_TRANSFORM, "Screw Modifier"); + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "Screw Modifier"); } } diff --git a/source/blender/modifiers/intern/MOD_simpledeform.c b/source/blender/modifiers/intern/MOD_simpledeform.c index cab1a24fe85..f1ad93e7182 100644 --- a/source/blender/modifiers/intern/MOD_simpledeform.c +++ b/source/blender/modifiers/intern/MOD_simpledeform.c @@ -376,6 +376,7 @@ static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphConte SimpleDeformModifierData *smd = (SimpleDeformModifierData *)md; if (smd->origin != NULL) { DEG_add_object_relation(ctx->node, smd->origin, DEG_OB_COMP_TRANSFORM, "SimpleDeform Modifier"); + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "SimpleDeform Modifier"); } } diff --git a/source/blender/modifiers/intern/MOD_uvproject.c b/source/blender/modifiers/intern/MOD_uvproject.c index 3aaf67792c6..8c9fbefa27a 100644 --- a/source/blender/modifiers/intern/MOD_uvproject.c +++ b/source/blender/modifiers/intern/MOD_uvproject.c @@ -104,12 +104,16 @@ static void foreachIDLink( static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphContext *ctx) { UVProjectModifierData *umd = (UVProjectModifierData *)md; - int i; - for (i = 0; i < umd->num_projectors; ++i) { + bool do_add_own_transform = false; + for (int i = 0; i < umd->num_projectors; ++i) { if (umd->projectors[i] != NULL) { DEG_add_object_relation(ctx->node, umd->projectors[i], DEG_OB_COMP_TRANSFORM, "UV Project Modifier"); + do_add_own_transform = true; } } + if (do_add_own_transform) { + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "UV Project Modifier"); + } } typedef struct Projector { diff --git a/source/blender/modifiers/intern/MOD_uvwarp.c b/source/blender/modifiers/intern/MOD_uvwarp.c index f92056d503f..e9947826fb6 100644 --- a/source/blender/modifiers/intern/MOD_uvwarp.c +++ b/source/blender/modifiers/intern/MOD_uvwarp.c @@ -244,6 +244,8 @@ static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphConte uv_warp_deps_object_bone_new(ctx->node, umd->object_src, umd->bone_src); uv_warp_deps_object_bone_new(ctx->node, umd->object_dst, umd->bone_dst); + + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "UVWarp Modifier"); } ModifierTypeInfo modifierType_UVWarp = { diff --git a/source/blender/modifiers/intern/MOD_warp.c b/source/blender/modifiers/intern/MOD_warp.c index aa81b945b4c..aea530e7b6e 100644 --- a/source/blender/modifiers/intern/MOD_warp.c +++ b/source/blender/modifiers/intern/MOD_warp.c @@ -143,6 +143,7 @@ static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphConte { WarpModifierData *wmd = (WarpModifierData *) md; if (wmd->object_from != NULL && wmd->object_to != NULL) { + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "Warplace Modifier"); DEG_add_object_relation(ctx->node, wmd->object_from, DEG_OB_COMP_TRANSFORM, "Warp Modifier from"); DEG_add_object_relation(ctx->node, wmd->object_to, DEG_OB_COMP_TRANSFORM, "Warp Modifier to"); } diff --git a/source/blender/modifiers/intern/MOD_wave.c b/source/blender/modifiers/intern/MOD_wave.c index 553f552bb0a..a517f753791 100644 --- a/source/blender/modifiers/intern/MOD_wave.c +++ b/source/blender/modifiers/intern/MOD_wave.c @@ -123,6 +123,9 @@ static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphConte if (wmd->map_object != NULL) { DEG_add_object_relation(ctx->node, wmd->map_object, DEG_OB_COMP_TRANSFORM, "Wave Modifier"); } + if (wmd->objectcenter != NULL || wmd->map_object != NULL) { + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "Wave Modifier"); + } } static CustomDataMask requiredDataMask(Object *UNUSED(ob), ModifierData *md) diff --git a/source/blender/modifiers/intern/MOD_weightvgedit.c b/source/blender/modifiers/intern/MOD_weightvgedit.c index 4bbf73caf92..bf7517ee634 100644 --- a/source/blender/modifiers/intern/MOD_weightvgedit.c +++ b/source/blender/modifiers/intern/MOD_weightvgedit.c @@ -142,8 +142,9 @@ static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphConte WeightVGEditModifierData *wmd = (WeightVGEditModifierData *)md; if (wmd->mask_tex_map_obj != NULL && wmd->mask_tex_mapping == MOD_DISP_MAP_OBJECT) { DEG_add_object_relation(ctx->node, wmd->mask_tex_map_obj, DEG_OB_COMP_TRANSFORM, "WeightVGEdit Modifier"); + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "WeightVGEdit Modifier"); } - if (wmd->mask_tex_mapping == MOD_DISP_MAP_GLOBAL) { + else if (wmd->mask_tex_mapping == MOD_DISP_MAP_GLOBAL) { DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "WeightVGEdit Modifier"); } } diff --git a/source/blender/modifiers/intern/MOD_weightvgmix.c b/source/blender/modifiers/intern/MOD_weightvgmix.c index c7a5d4dc70d..674ef106737 100644 --- a/source/blender/modifiers/intern/MOD_weightvgmix.c +++ b/source/blender/modifiers/intern/MOD_weightvgmix.c @@ -178,8 +178,10 @@ static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphConte if (wmd->mask_tex_map_obj != NULL && wmd->mask_tex_mapping == MOD_DISP_MAP_OBJECT) { DEG_add_object_relation(ctx->node, wmd->mask_tex_map_obj, DEG_OB_COMP_TRANSFORM, "WeightVGMix Modifier"); DEG_add_object_relation(ctx->node, wmd->mask_tex_map_obj, DEG_OB_COMP_GEOMETRY, "WeightVGMix Modifier"); + + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "WeightVGMix Modifier"); } - if (wmd->mask_tex_mapping == MOD_DISP_MAP_GLOBAL) { + else if (wmd->mask_tex_mapping == MOD_DISP_MAP_GLOBAL) { DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "WeightVGMix Modifier"); DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_GEOMETRY, "WeightVGMix Modifier"); } diff --git a/source/blender/modifiers/intern/MOD_weightvgproximity.c b/source/blender/modifiers/intern/MOD_weightvgproximity.c index bf220517342..6facccaf57a 100644 --- a/source/blender/modifiers/intern/MOD_weightvgproximity.c +++ b/source/blender/modifiers/intern/MOD_weightvgproximity.c @@ -352,10 +352,8 @@ static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphConte DEG_add_object_relation(ctx->node, wmd->mask_tex_map_obj, DEG_OB_COMP_TRANSFORM, "WeightVGProximity Modifier"); DEG_add_object_relation(ctx->node, wmd->mask_tex_map_obj, DEG_OB_COMP_GEOMETRY, "WeightVGProximity Modifier"); } - if (wmd->mask_tex_mapping == MOD_DISP_MAP_GLOBAL) { - DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "WeightVGProximity Modifier"); - DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_GEOMETRY, "WeightVGProximity Modifier"); - } + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, "WeightVGProximity Modifier"); + DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_GEOMETRY, "WeightVGProximity Modifier"); } static bool isDisabled(const struct Scene *UNUSED(scene), ModifierData *md, bool UNUSED(useRenderParams)) |