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:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2010-12-05 21:59:23 +0300
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2010-12-05 21:59:23 +0300
commitb110c7c8f2c5fafa6412e01d21d751a884bfe8b2 (patch)
treec414d8b62a65c8d633625498dd36740548605c4c /source/blender/editors/transform
parent07692fc59b1837da7510e46c37d0deed85924a52 (diff)
Dependency graph: changed DAG_id_flush_update to DAG_id_tag_update. Now it
only tags the ID and does the actual flush/update delayed, before the next redraw. For objects the update was already delayed, just flushing wasn't yet. This should help performance in python and animation editors, by making calls to RNA property update quicker. Still need to add calls in a few places where this was previously avoided due to bad performance.
Diffstat (limited to 'source/blender/editors/transform')
-rw-r--r--source/blender/editors/transform/transform_conversions.c12
-rw-r--r--source/blender/editors/transform/transform_generics.c14
2 files changed, 13 insertions, 13 deletions
diff --git a/source/blender/editors/transform/transform_conversions.c b/source/blender/editors/transform/transform_conversions.c
index 1f05f8bb668..1aac6e72228 100644
--- a/source/blender/editors/transform/transform_conversions.c
+++ b/source/blender/editors/transform/transform_conversions.c
@@ -4861,9 +4861,9 @@ void special_aftertrans_update(bContext *C, TransInfo *t)
// fixme... some of this stuff is not good
if (ob) {
if (ob->pose || ob_get_key(ob))
- DAG_id_flush_update(&ob->id, OB_RECALC_ALL);
+ DAG_id_tag_update(&ob->id, OB_RECALC_ALL);
else
- DAG_id_flush_update(&ob->id, OB_RECALC_OB);
+ DAG_id_tag_update(&ob->id, OB_RECALC_OB);
}
/* Do curve cleanups? */
@@ -5032,15 +5032,15 @@ void special_aftertrans_update(bContext *C, TransInfo *t)
/* automatic inserting of keys and unkeyed tagging - only if transform wasn't cancelled (or TFM_DUMMY) */
if (!cancelled && (t->mode != TFM_DUMMY)) {
autokeyframe_pose_cb_func(C, t->scene, (View3D *)t->view, ob, t->mode, targetless_ik);
- DAG_id_flush_update(&ob->id, OB_RECALC_DATA);
+ DAG_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_flush_update(&ob->id, OB_RECALC_DATA);
+ DAG_id_tag_update(&ob->id, OB_RECALC_DATA);
ob->recalc= 0; // is set on OK position already by recalcData()
}
else
- DAG_id_flush_update(&ob->id, OB_RECALC_DATA);
+ DAG_id_tag_update(&ob->id, OB_RECALC_DATA);
}
else if(t->scene->basact && (ob = t->scene->basact->object) && (ob->mode & OB_MODE_PARTICLE_EDIT) && PE_get_current(t->scene, ob)) {
@@ -5077,7 +5077,7 @@ void special_aftertrans_update(bContext *C, TransInfo *t)
/* 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_flush_update(&ob->id, OB_RECALC_OB);
+ DAG_id_tag_update(&ob->id, OB_RECALC_OB);
/* Set autokey if necessary */
if (!cancelled) {
diff --git a/source/blender/editors/transform/transform_generics.c b/source/blender/editors/transform/transform_generics.c
index 21ec46de6af..8148e10b5d2 100644
--- a/source/blender/editors/transform/transform_generics.c
+++ b/source/blender/editors/transform/transform_generics.c
@@ -616,7 +616,7 @@ void recalcData(TransInfo *t)
if(sima->flag & SI_LIVE_UNWRAP)
ED_uvedit_live_unwrap_re_solve();
- DAG_id_flush_update(t->obedit->data, OB_RECALC_DATA);
+ DAG_id_tag_update(t->obedit->data, OB_RECALC_DATA);
}
}
else if (t->spacetype == SPACE_VIEW3D) {
@@ -632,7 +632,7 @@ void recalcData(TransInfo *t)
applyProject(t);
}
- DAG_id_flush_update(t->obedit->data, OB_RECALC_DATA); /* sets recalc flags */
+ DAG_id_tag_update(t->obedit->data, OB_RECALC_DATA); /* sets recalc flags */
if (t->state == TRANS_CANCEL) {
while(nu) {
@@ -655,7 +655,7 @@ void recalcData(TransInfo *t)
applyProject(t);
}
- DAG_id_flush_update(t->obedit->data, OB_RECALC_DATA); /* sets recalc flags */
+ DAG_id_tag_update(t->obedit->data, OB_RECALC_DATA); /* sets recalc flags */
if(la->editlatt->latt->flag & LT_OUTSIDE) outside_lattice(la->editlatt->latt);
}
@@ -669,7 +669,7 @@ void recalcData(TransInfo *t)
if((t->options & CTX_NO_MIRROR) == 0 && (t->flag & T_MIRROR))
editmesh_apply_to_mirror(t);
- DAG_id_flush_update(t->obedit->data, OB_RECALC_DATA); /* sets recalc flags */
+ DAG_id_tag_update(t->obedit->data, OB_RECALC_DATA); /* sets recalc flags */
recalc_editnormals(em);
}
@@ -760,7 +760,7 @@ void recalcData(TransInfo *t)
if(t->state != TRANS_CANCEL) {
applyProject(t);
}
- DAG_id_flush_update(t->obedit->data, OB_RECALC_DATA); /* sets recalc flags */
+ DAG_id_tag_update(t->obedit->data, OB_RECALC_DATA); /* sets recalc flags */
}
}
else if( (t->flag & T_POSE) && t->poseobj) {
@@ -781,7 +781,7 @@ void recalcData(TransInfo *t)
/* old optimize trick... this enforces to bypass the depgraph */
if (!(arm->flag & ARM_DELAYDEFORM)) {
- DAG_id_flush_update(&ob->id, OB_RECALC_DATA); /* sets recalc flags */
+ DAG_id_tag_update(&ob->id, OB_RECALC_DATA); /* sets recalc flags */
}
else
where_is_pose(t->scene, ob);
@@ -822,7 +822,7 @@ void recalcData(TransInfo *t)
/* sets recalc flags fully, instead of flushing existing ones
* otherwise proxies don't function correctly
*/
- DAG_id_flush_update(&ob->id, OB_RECALC_OB);
+ DAG_id_tag_update(&ob->id, OB_RECALC_OB);
}
}