diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2017-10-24 16:29:43 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2017-10-24 17:04:11 +0300 |
commit | 97b2483a7a78253fcbd4dd5d114a1c7a8668c4ef (patch) | |
tree | 54c1122deff3982e669229b241b5f3d361e975de /source | |
parent | 11d8c939cd66714b22fa5b1763d88ce2d78241e4 (diff) |
Depsgraph: Remove scene from refresh API
Scene is already stored in the graph.
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/blenkernel/intern/scene.c | 2 | ||||
-rw-r--r-- | source/blender/depsgraph/DEG_depsgraph.h | 3 | ||||
-rw-r--r-- | source/blender/depsgraph/intern/depsgraph_eval.cc | 5 |
3 files changed, 4 insertions, 6 deletions
diff --git a/source/blender/blenkernel/intern/scene.c b/source/blender/blenkernel/intern/scene.c index 4662612cc24..5477ab97201 100644 --- a/source/blender/blenkernel/intern/scene.c +++ b/source/blender/blenkernel/intern/scene.c @@ -1623,7 +1623,7 @@ void BKE_scene_update_tagged(EvaluationContext *eval_ctx, Main *bmain, Scene *sc * * in the future this should handle updates for all datablocks, not * only objects and scenes. - brecht */ - DEG_evaluate_on_refresh(eval_ctx, scene->depsgraph_legacy, scene); + DEG_evaluate_on_refresh(eval_ctx, scene->depsgraph_legacy); /* update sound system animation (TODO, move to depsgraph) */ BKE_sound_update_scene(bmain, scene); diff --git a/source/blender/depsgraph/DEG_depsgraph.h b/source/blender/depsgraph/DEG_depsgraph.h index 6391cb71866..c47ddb711a6 100644 --- a/source/blender/depsgraph/DEG_depsgraph.h +++ b/source/blender/depsgraph/DEG_depsgraph.h @@ -228,8 +228,7 @@ void DEG_evaluate_on_framechange(struct EvaluationContext *eval_ctx, * < context_type: context to perform evaluation for */ void DEG_evaluate_on_refresh(struct EvaluationContext *eval_ctx, - Depsgraph *graph, - struct Scene *scene); + Depsgraph *graph); bool DEG_needs_eval(Depsgraph *graph); diff --git a/source/blender/depsgraph/intern/depsgraph_eval.cc b/source/blender/depsgraph/intern/depsgraph_eval.cc index 03c2f0742fc..176466fe058 100644 --- a/source/blender/depsgraph/intern/depsgraph_eval.cc +++ b/source/blender/depsgraph/intern/depsgraph_eval.cc @@ -100,13 +100,12 @@ void DEG_evaluation_context_free(EvaluationContext *eval_ctx) /* Evaluate all nodes tagged for updating. */ void DEG_evaluate_on_refresh(EvaluationContext *eval_ctx, - Depsgraph *graph, - Scene *scene) + Depsgraph *graph) { DEG::Depsgraph *deg_graph = reinterpret_cast<DEG::Depsgraph *>(graph); /* Update time on primary timesource. */ DEG::TimeSourceDepsNode *tsrc = deg_graph->find_time_source(); - tsrc->cfra = BKE_scene_frame_get(scene); + tsrc->cfra = BKE_scene_frame_get(deg_graph->scene); DEG::deg_evaluate_on_refresh(eval_ctx, deg_graph); } |