diff options
author | Brecht Van Lommel <brecht@blender.org> | 2021-04-05 00:51:24 +0300 |
---|---|---|
committer | Brecht Van Lommel <brecht@blender.org> | 2021-04-05 15:05:01 +0300 |
commit | 50782df42586a5a038cad11530714371edaa5cd4 (patch) | |
tree | f2f6e3d5c4f07be85efd39e1319fdb49b76d1d2d /source/blender/depsgraph/intern/depsgraph.cc | |
parent | 3fa580866ef5514f6fa7f9c5a369249f69135c78 (diff) |
Render: faster animation and re-rendering with Persistent Data
For Cycles, when enabling the Persistent Data option, the full render data
will be preserved from frame-to-frame in animation renders and between
re-renders of the scene. This means that any modifier evaluation, BVH
building, OpenGL vertex buffer uploads, etc, can be done only once for
unchanged objects. This comes at an increased memory cost.
Previously there option was named Persistent Images and had a more limited
impact on render time and memory.
When using multiple view layers, only data from a single view layer is
preserved to keep memory usage somewhat under control. However objects
shared between view layers are preserved, and so this can speedup such
renders as well, even single frame renders.
For Eevee and Workbench this option is not available, however these engines
will now always reuse the depsgraph for animation and multiple view layers.
This can significantly speed up rendering.
These engines do not support sharing the depsgraph between re-renders, due
to technical issues regarding OpenGL contexts. Support for this could be added
if those are solved, see the code comments for details.
Diffstat (limited to 'source/blender/depsgraph/intern/depsgraph.cc')
-rw-r--r-- | source/blender/depsgraph/intern/depsgraph.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/source/blender/depsgraph/intern/depsgraph.cc b/source/blender/depsgraph/intern/depsgraph.cc index 3d30e7e79b9..8e1ab23fae0 100644 --- a/source/blender/depsgraph/intern/depsgraph.cc +++ b/source/blender/depsgraph/intern/depsgraph.cc @@ -70,7 +70,8 @@ Depsgraph::Depsgraph(Main *bmain, Scene *scene, ViewLayer *view_layer, eEvaluati scene_cow(nullptr), is_active(false), is_evaluating(false), - is_render_pipeline_depsgraph(false) + is_render_pipeline_depsgraph(false), + use_editors_update(false) { BLI_spin_init(&lock); memset(id_type_updated, 0, sizeof(id_type_updated)); @@ -285,7 +286,9 @@ Depsgraph *DEG_graph_new(Main *bmain, Scene *scene, ViewLayer *view_layer, eEval } /* Replace the "owner" pointers (currently Main/Scene/ViewLayer) of this depsgraph. - * Used during undo steps when we do want to re-use the old depsgraph data as much as possible. */ + * Used for: + * - Undo steps when we do want to re-use the old depsgraph data as much as possible. + * - Rendering where we want to re-use objects between different view layers. */ void DEG_graph_replace_owners(struct Depsgraph *depsgraph, Main *bmain, Scene *scene, |