Depsgraph: simplify build API

Reviewers: sergey, sybren

Differential Revision: https://developer.blender.org/D8611
This commit is contained in:
2020-08-18 15:51:32 +02:00
parent d9f7cbb8af
commit 6a4f5e6a8c
31 changed files with 61 additions and 122 deletions

View File

@@ -75,12 +75,11 @@ static void export_startjob(void *customdata,
// Construct the depsgraph for exporting.
Scene *scene = DEG_get_input_scene(data->depsgraph);
ViewLayer *view_layer = DEG_get_input_view_layer(data->depsgraph);
if (data->params.visible_objects_only) {
DEG_graph_build_from_view_layer(data->depsgraph, data->bmain, scene, view_layer);
DEG_graph_build_from_view_layer(data->depsgraph);
}
else {
DEG_graph_build_for_all_objects(data->depsgraph, data->bmain, scene, view_layer);
DEG_graph_build_for_all_objects(data->depsgraph);
}
BKE_scene_graph_update_tagged(data->depsgraph, data->bmain);