diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-04-17 07:17:24 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-04-17 07:21:24 +0300 |
commit | e12c08e8d170b7ca40f204a5b0423c23a9fbc2c1 (patch) | |
tree | 8cf3453d12edb177a218ef8009357518ec6cab6a /source/blender/depsgraph/intern/depsgraph_eval.cc | |
parent | b3dabc200a4b0399ec6b81f2ff2730d07b44fcaa (diff) |
ClangFormat: apply to source, most of intern
Apply clang format as proposed in T53211.
For details on usage and instructions for migrating branches
without conflicts, see:
https://wiki.blender.org/wiki/Tools/ClangFormat
Diffstat (limited to 'source/blender/depsgraph/intern/depsgraph_eval.cc')
-rw-r--r-- | source/blender/depsgraph/intern/depsgraph_eval.cc | 54 |
1 files changed, 26 insertions, 28 deletions
diff --git a/source/blender/depsgraph/intern/depsgraph_eval.cc b/source/blender/depsgraph/intern/depsgraph_eval.cc index 30370c5ac15..6f3262174b4 100644 --- a/source/blender/depsgraph/intern/depsgraph_eval.cc +++ b/source/blender/depsgraph/intern/depsgraph_eval.cc @@ -51,40 +51,38 @@ extern "C" { /* Evaluate all nodes tagged for updating. */ void DEG_evaluate_on_refresh(Depsgraph *graph) { - DEG::Depsgraph *deg_graph = reinterpret_cast<DEG::Depsgraph *>(graph); - deg_graph->ctime = BKE_scene_frame_get(deg_graph->scene); - /* Update time on primary timesource. */ - DEG::TimeSourceNode *tsrc = deg_graph->find_time_source(); - tsrc->cfra = deg_graph->ctime; - /* Update time in scene. */ - if (deg_graph->scene_cow) { - BKE_scene_frame_set(deg_graph->scene_cow, deg_graph->ctime); - } - DEG::deg_evaluate_on_refresh(deg_graph); + DEG::Depsgraph *deg_graph = reinterpret_cast<DEG::Depsgraph *>(graph); + deg_graph->ctime = BKE_scene_frame_get(deg_graph->scene); + /* Update time on primary timesource. */ + DEG::TimeSourceNode *tsrc = deg_graph->find_time_source(); + tsrc->cfra = deg_graph->ctime; + /* Update time in scene. */ + if (deg_graph->scene_cow) { + BKE_scene_frame_set(deg_graph->scene_cow, deg_graph->ctime); + } + DEG::deg_evaluate_on_refresh(deg_graph); } /* Frame-change happened for root scene that graph belongs to. */ -void DEG_evaluate_on_framechange(Main *bmain, - Depsgraph *graph, - float ctime) +void DEG_evaluate_on_framechange(Main *bmain, Depsgraph *graph, float ctime) { - DEG::Depsgraph *deg_graph = reinterpret_cast<DEG::Depsgraph *>(graph); - deg_graph->ctime = ctime; - /* Update time on primary timesource. */ - DEG::TimeSourceNode *tsrc = deg_graph->find_time_source(); - tsrc->cfra = ctime; - tsrc->tag_update(deg_graph, DEG::DEG_UPDATE_SOURCE_TIME); - DEG::deg_graph_flush_updates(bmain, deg_graph); - /* Update time in scene. */ - if (deg_graph->scene_cow) { - BKE_scene_frame_set(deg_graph->scene_cow, deg_graph->ctime); - } - /* Perform recalculation updates. */ - DEG::deg_evaluate_on_refresh(deg_graph); + DEG::Depsgraph *deg_graph = reinterpret_cast<DEG::Depsgraph *>(graph); + deg_graph->ctime = ctime; + /* Update time on primary timesource. */ + DEG::TimeSourceNode *tsrc = deg_graph->find_time_source(); + tsrc->cfra = ctime; + tsrc->tag_update(deg_graph, DEG::DEG_UPDATE_SOURCE_TIME); + DEG::deg_graph_flush_updates(bmain, deg_graph); + /* Update time in scene. */ + if (deg_graph->scene_cow) { + BKE_scene_frame_set(deg_graph->scene_cow, deg_graph->ctime); + } + /* Perform recalculation updates. */ + DEG::deg_evaluate_on_refresh(deg_graph); } 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::Depsgraph *deg_graph = reinterpret_cast<DEG::Depsgraph *>(graph); + return BLI_gset_len(deg_graph->entry_tags) != 0; } |