From 46a256b5d1a105ed07f4817fc74cfc52266dd50a Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Thu, 26 Apr 2018 17:22:17 +0200 Subject: Depsgraph: Make it possible to check for ID directly tagged for animation recalc --- source/blender/depsgraph/intern/depsgraph_tag.cc | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'source/blender/depsgraph/intern') diff --git a/source/blender/depsgraph/intern/depsgraph_tag.cc b/source/blender/depsgraph/intern/depsgraph_tag.cc index 826194c09a3..7c49cb5100d 100644 --- a/source/blender/depsgraph/intern/depsgraph_tag.cc +++ b/source/blender/depsgraph/intern/depsgraph_tag.cc @@ -376,6 +376,15 @@ void deg_graph_id_tag_update_single_flag(Main *bmain, DepsNodeFactory *factory = deg_type_get_factory(component_type); BLI_assert(factory != NULL); id->recalc |= factory->id_recalc_tag(); + /* NOTE: This way we clearly separate direct animation recalc flag from + * a flushed one. Needed for auto-keyframe hack feature. + * + * TODO(sergey): Find a more generic way to set/access direct tagged ID + * recalc flags. + */ + if (tag == DEG_TAG_TIME) { + id->recalc |= ID_RECALC_TIME; + } /* Some sanity checks before moving forward. */ if (id_node == NULL) { /* Happens when object is tagged for update and not yet in the -- cgit v1.2.3