From d675415eef9f565b1828f48dfe874321af1c4af8 Mon Sep 17 00:00:00 2001 From: Luca Rood Date: Thu, 8 Jun 2017 10:14:53 +0200 Subject: Replace all old DAG calls with direct calls to new DEG and remove BKE_depsgraph.h This removes BKE_depsgraph.h and depsgraph.c --- .../editors/transform/transform_conversions.c | 28 +++++++++++----------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'source/blender/editors/transform/transform_conversions.c') diff --git a/source/blender/editors/transform/transform_conversions.c b/source/blender/editors/transform/transform_conversions.c index 54c943661c0..7c45eaef51c 100644 --- a/source/blender/editors/transform/transform_conversions.c +++ b/source/blender/editors/transform/transform_conversions.c @@ -68,7 +68,6 @@ #include "BKE_context.h" #include "BKE_crazyspace.h" #include "BKE_curve.h" -#include "BKE_depsgraph.h" #include "BKE_fcurve.h" #include "BKE_global.h" #include "BKE_gpencil.h" @@ -119,6 +118,7 @@ #include "RNA_access.h" #include "DEG_depsgraph.h" +#include "DEG_depsgraph_build.h" #include "transform.h" #include "bmesh.h" @@ -858,7 +858,7 @@ static void pose_grab_with_ik_clear(Object *ob) } /* TODO(sergey): Consider doing partial update only. */ - DAG_relations_tag_update(G.main); + DEG_relations_tag_update(G.main); } /* adds the IK to pchan - returns if added */ @@ -1012,7 +1012,7 @@ static short pose_grab_with_ik(Object *ob) if (tot_ik) { BIK_clear_data(ob->pose); /* TODO(sergey): Consuder doing partial update only. */ - DAG_relations_tag_update(G.main); + DEG_relations_tag_update(G.main); } return (tot_ik) ? 1 : 0; @@ -5448,7 +5448,7 @@ static void set_trans_object_base_flags(TransInfo *t) BKE_scene_base_flag_to_objects(t->scene_layer); /* Make sure depsgraph is here. */ - DAG_scene_relations_update(G.main, t->scene); + DEG_scene_relations_update(G.main, t->scene); /* handle pending update events, otherwise they got copied below */ for (base = sl->object_bases.first; base; base = base->next) { @@ -5490,7 +5490,7 @@ static void set_trans_object_base_flags(TransInfo *t) base->flag_legacy |= BA_WAS_SEL; } } - DAG_id_tag_update(&ob->id, OB_RECALC_OB); + DEG_id_tag_update(&ob->id, OB_RECALC_OB); } } @@ -5563,7 +5563,7 @@ static int count_proportional_objects(TransInfo *t) (BASE_EDITABLE_BGMODE_NEW(base))) { - DAG_id_tag_update(&ob->id, OB_RECALC_OB); + DEG_id_tag_update(&ob->id, OB_RECALC_OB); total += 1; } @@ -5571,7 +5571,7 @@ static int count_proportional_objects(TransInfo *t) /* all recalc flags get flushed to all layers, so a layer flip later on works fine */ - DAG_scene_relations_update(G.main, t->scene); + DEG_scene_relations_update(G.main, t->scene); /* and we store them temporal in base (only used for transform code) */ /* this because after doing updates, the object->recalc is cleared */ @@ -6156,9 +6156,9 @@ void special_aftertrans_update(bContext *C, TransInfo *t) // fixme... some of this stuff is not good if (ob) { if (ob->pose || BKE_key_from_object(ob)) - DAG_id_tag_update(&ob->id, OB_RECALC_OB | OB_RECALC_DATA | OB_RECALC_TIME); + DEG_id_tag_update(&ob->id, OB_RECALC_OB | OB_RECALC_DATA | OB_RECALC_TIME); else - DAG_id_tag_update(&ob->id, OB_RECALC_OB); + DEG_id_tag_update(&ob->id, OB_RECALC_OB); } /* 3 cases here for curve cleanups: @@ -6368,15 +6368,15 @@ void special_aftertrans_update(bContext *C, TransInfo *t) /* automatic inserting of keys and unkeyed tagging - only if transform wasn't canceled (or TFM_DUMMY) */ if (!canceled && (t->mode != TFM_DUMMY)) { autokeyframe_pose_cb_func(C, t->scene, (View3D *)t->view, ob, t->mode, targetless_ik); - DAG_id_tag_update(&ob->id, OB_RECALC_DATA); + DEG_id_tag_update(&ob->id, OB_RECALC_DATA); } else if (arm->flag & ARM_DELAYDEFORM) { /* old optimize trick... this enforces to bypass the depgraph */ - DAG_id_tag_update(&ob->id, OB_RECALC_DATA); + DEG_id_tag_update(&ob->id, OB_RECALC_DATA); ob->recalc = 0; // is set on OK position already by recalcData() } else - DAG_id_tag_update(&ob->id, OB_RECALC_DATA); + DEG_id_tag_update(&ob->id, OB_RECALC_DATA); } else if (t->options & CTX_PAINT_CURVE) { @@ -6416,13 +6416,13 @@ void special_aftertrans_update(bContext *C, TransInfo *t) /* pointcache refresh */ if (BKE_ptcache_object_reset(t->scene, ob, PTCACHE_RESET_OUTDATED)) - DAG_id_tag_update(&ob->id, OB_RECALC_DATA); + DEG_id_tag_update(&ob->id, OB_RECALC_DATA); /* Needed for proper updating of "quick cached" dynamics. */ /* Creates troubles for moving animated objects without */ /* autokey though, probably needed is an anim sys override? */ /* Please remove if some other solution is found. -jahka */ - DAG_id_tag_update(&ob->id, OB_RECALC_OB); + DEG_id_tag_update(&ob->id, OB_RECALC_OB); /* Set autokey if necessary */ if (!canceled) { -- cgit v1.2.3