Page MenuHome
Paste P1129

Revert 1693a5efe91
ActivePublic

Authored by Sergey Sharybin (sergey) on Oct 6 2019, 9:22 PM.
diff --git a/source/blender/depsgraph/intern/depsgraph.cc b/source/blender/depsgraph/intern/depsgraph.cc
index dcdea87fe1a..8b2035340b5 100644
--- a/source/blender/depsgraph/intern/depsgraph.cc
+++ b/source/blender/depsgraph/intern/depsgraph.cc
@@ -68,7 +68,6 @@ template<typename T> static void remove_from_vector(vector<T> *vector, const T &
Depsgraph::Depsgraph(Main *bmain, Scene *scene, ViewLayer *view_layer, eEvaluationMode mode)
: time_source(NULL),
need_update(true),
- need_update_time(false),
bmain(bmain),
scene(scene),
view_layer(view_layer),
diff --git a/source/blender/depsgraph/intern/depsgraph.h b/source/blender/depsgraph/intern/depsgraph.h
index 30ae4edde34..f32a54fab20 100644
--- a/source/blender/depsgraph/intern/depsgraph.h
+++ b/source/blender/depsgraph/intern/depsgraph.h
@@ -158,10 +158,6 @@ struct Depsgraph {
/* Nodes which have been tagged as "directly modified". */
GSet *entry_tags;
- /* Special entry tag for time source. Allows to tag invisible dependency graphs for update when
- * scene frame changes, so then when dependency graph becomes visible it is on a proper state. */
- bool need_update_time;
-
/* Convenience Data ................... */
/* XXX: should be collected after building (if actually needed?) */
diff --git a/source/blender/depsgraph/intern/depsgraph_eval.cc b/source/blender/depsgraph/intern/depsgraph_eval.cc
index b2b7d2a9d00..41a387572b7 100644
--- a/source/blender/depsgraph/intern/depsgraph_eval.cc
+++ b/source/blender/depsgraph/intern/depsgraph_eval.cc
@@ -62,7 +62,6 @@ void DEG_evaluate_on_refresh(Main *bmain, Depsgraph *graph)
}
DEG::deg_graph_flush_updates(bmain, deg_graph);
DEG::deg_evaluate_on_refresh(deg_graph);
- deg_graph->need_update_time = false;
}
/* Frame-change happened for root scene that graph belongs to. */
@@ -81,11 +80,10 @@ void DEG_evaluate_on_framechange(Main *bmain, Depsgraph *graph, float ctime)
}
/* Perform recalculation updates. */
DEG::deg_evaluate_on_refresh(deg_graph);
- deg_graph->need_update_time = false;
}
bool DEG_needs_eval(Depsgraph *graph)
{
DEG::Depsgraph *deg_graph = reinterpret_cast<DEG::Depsgraph *>(graph);
- return BLI_gset_len(deg_graph->entry_tags) != 0 || deg_graph->need_update_time;
+ return BLI_gset_len(deg_graph->entry_tags) != 0;
}
diff --git a/source/blender/depsgraph/intern/depsgraph_tag.cc b/source/blender/depsgraph/intern/depsgraph_tag.cc
index 2fdce0e30a5..8efb097cab2 100644
--- a/source/blender/depsgraph/intern/depsgraph_tag.cc
+++ b/source/blender/depsgraph/intern/depsgraph_tag.cc
@@ -232,9 +232,6 @@ void depsgraph_tag_to_component_opcode(const ID *id,
case ID_RECALC_SOURCE:
*component_type = NodeType::PARAMETERS;
break;
- case ID_RECALC_TIME:
- BLI_assert(!"Should be handled outside of this function");
- break;
case ID_RECALC_ALL:
case ID_RECALC_PSYS_ALL:
BLI_assert(!"Should not happen");
@@ -372,12 +369,6 @@ static void graph_id_tag_update_single_flag(Main *bmain,
}
return;
}
- else if (tag == ID_RECALC_TIME) {
- if (graph != NULL) {
- graph->need_update_time = true;
- }
- return;
- }
/* Get description of what is to be tagged. */
NodeType component_type;
OperationCode operation_code;
@@ -709,8 +700,6 @@ const char *DEG_update_tag_as_string(IDRecalcFlag flag)
return "AUDIO";
case ID_RECALC_PARAMETERS:
return "PARAMETERS";
- case ID_RECALC_TIME:
- return "TIME";
case ID_RECALC_SOURCE:
return "SOURCE";
case ID_RECALC_ALL:
diff --git a/source/blender/depsgraph/intern/eval/deg_eval_flush.cc b/source/blender/depsgraph/intern/eval/deg_eval_flush.cc
index 2479373b687..cffc3e21f92 100644
--- a/source/blender/depsgraph/intern/eval/deg_eval_flush.cc
+++ b/source/blender/depsgraph/intern/eval/deg_eval_flush.cc
@@ -351,16 +351,9 @@ void deg_graph_flush_updates(Main *bmain, Depsgraph *graph)
BLI_assert(bmain != NULL);
BLI_assert(graph != NULL);
/* Nothing to update, early out. */
- if (BLI_gset_len(graph->entry_tags) == 0 && !graph->need_update_time) {
+ if (BLI_gset_len(graph->entry_tags) == 0) {
return;
}
- if (graph->need_update_time) {
- const Scene *scene_orig = graph->scene;
- const float ctime = BKE_scene_frame_get(scene_orig);
- DEG::TimeSourceNode *time_source = graph->find_time_source();
- graph->ctime = ctime;
- time_source->tag_update(graph, DEG::DEG_UPDATE_SOURCE_TIME);
- }
/* Reset all flags, get ready for the flush. */
flush_prepare(graph);
/* Starting from the tagged "entry" nodes, flush outwards. */
diff --git a/source/blender/editors/screen/screen_edit.c b/source/blender/editors/screen/screen_edit.c
index bbdddfadc30..14a2742ca3e 100644
--- a/source/blender/editors/screen/screen_edit.c
+++ b/source/blender/editors/screen/screen_edit.c
@@ -1545,8 +1545,6 @@ void ED_update_for_newframe(Main *bmain, Depsgraph *depsgraph)
{
Scene *scene = DEG_get_input_scene(depsgraph);
- DEG_id_tag_update_ex(bmain, &scene->id, ID_RECALC_TIME);
-
#ifdef DURIAN_CAMERA_SWITCH
void *camera = BKE_scene_camera_switch_find(scene);
if (camera && scene->camera != camera) {
diff --git a/source/blender/makesdna/DNA_ID.h b/source/blender/makesdna/DNA_ID.h
index a6212e09567..61b6e7ad7f8 100644
--- a/source/blender/makesdna/DNA_ID.h
+++ b/source/blender/makesdna/DNA_ID.h
@@ -629,10 +629,6 @@ typedef enum IDRecalcFlag {
ID_RECALC_PARAMETERS = (1 << 21),
- /* Makes it so everything what depends on time.
- * Basically, the same what changing frame in a timeline will do. */
- ID_RECALC_TIME = (1 << 22),
-
/* Input has changed and datablock is to be reload from disk.
* Applies to movie clips to inform that copy-on-written version is to be refreshed for the new
* input file or for color space changes. */

Event Timeline

Sergey Sharybin (sergey) created this object with edit policy "Administrators".