diff options
Diffstat (limited to 'source/blender/depsgraph')
5 files changed, 10 insertions, 2 deletions
diff --git a/source/blender/depsgraph/DEG_depsgraph.h b/source/blender/depsgraph/DEG_depsgraph.h index 1941dc98d53..f817fc31fba 100644 --- a/source/blender/depsgraph/DEG_depsgraph.h +++ b/source/blender/depsgraph/DEG_depsgraph.h @@ -65,6 +65,7 @@ struct Main; struct PointerRNA; struct PropertyRNA; +struct SceneLayer; /* Dependency graph evaluation context * @@ -74,6 +75,8 @@ struct PropertyRNA; typedef struct EvaluationContext { int mode; float ctime; + + struct SceneLayer *scene_layer; } EvaluationContext; typedef enum eEvaluationMode { diff --git a/source/blender/depsgraph/DEG_depsgraph_build.h b/source/blender/depsgraph/DEG_depsgraph_build.h index 8c3ddec40a4..0e29f24f454 100644 --- a/source/blender/depsgraph/DEG_depsgraph_build.h +++ b/source/blender/depsgraph/DEG_depsgraph_build.h @@ -42,6 +42,7 @@ struct Depsgraph; struct CacheFile; struct EffectorWeights; +struct EvaluationContext; struct Group; struct Main; struct ModifierData; diff --git a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc index 93d9aab1898..f66a7b4c17a 100644 --- a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc +++ b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc @@ -324,7 +324,7 @@ void DepsgraphRelationBuilder::add_collision_relations(const OperationKey &key, void DepsgraphRelationBuilder::add_forcefield_relations(const OperationKey &key, Scene *scene, Object *ob, ParticleSystem *psys, EffectorWeights *eff, bool add_absorption, const char *name) { - ListBase *effectors = pdInitEffectors(scene, ob, psys, eff, false); + ListBase *effectors = pdInitEffectors(NULL, scene, ob, psys, eff, false); if (effectors) { for (EffectorCache *eff = (EffectorCache *)effectors->first; eff; eff = eff->next) { diff --git a/source/blender/depsgraph/intern/depsgraph_build.cc b/source/blender/depsgraph/intern/depsgraph_build.cc index 41934e3e4e6..68f14790d87 100644 --- a/source/blender/depsgraph/intern/depsgraph_build.cc +++ b/source/blender/depsgraph/intern/depsgraph_build.cc @@ -348,7 +348,7 @@ void DEG_add_forcefield_relations(DepsNodeHandle *handle, int skip_forcefield, const char *name) { - ListBase *effectors = pdInitEffectors(scene, ob, NULL, effector_weights, false); + ListBase *effectors = pdInitEffectors(NULL, scene, ob, NULL, effector_weights, false); if (effectors) { for (EffectorCache *eff = (EffectorCache*)effectors->first; eff; eff = eff->next) { diff --git a/source/blender/depsgraph/intern/eval/deg_eval.cc b/source/blender/depsgraph/intern/eval/deg_eval.cc index 15ad6b8054d..120785ac548 100644 --- a/source/blender/depsgraph/intern/eval/deg_eval.cc +++ b/source/blender/depsgraph/intern/eval/deg_eval.cc @@ -38,7 +38,10 @@ #include "BLI_task.h" #include "BLI_ghash.h" +#include "DNA_object_types.h" + #include "DEG_depsgraph.h" +#include "DEG_depsgraph_query.h" #include "atomic_ops.h" @@ -275,6 +278,7 @@ void deg_evaluate_on_refresh(EvaluationContext *eval_ctx, /* Set time for the current graph evaluation context. */ TimeSourceDepsNode *time_src = graph->find_time_source(); + eval_ctx->scene_layer = DEG_get_evaluated_scene_layer((::Depsgraph *)graph); eval_ctx->ctime = time_src->cfra; /* XXX could use a separate pool for each eval context */ |