Render: Propagate view updates to draw engines
Currently, draw engines are not notified of view updates if a render engine is active and was updated. It is unclear why this is the case currently, but this behavior was part of the initial commit. This patch propagates view updates regardless if the update was handled by an active render engine. This is needed by the realtime compositor as it implements logic for view updates, which currently does not execute if Cycles is rendering for instance. Differential Revision: https://developer.blender.org/D15207 Reviewed By: Brecht
This commit is contained in:
parent
4815772fda
commit
c3ca487498
|
@ -95,20 +95,20 @@ void ED_render_view3d_update(Depsgraph *depsgraph,
|
|||
|
||||
CTX_free(C);
|
||||
}
|
||||
else {
|
||||
RenderEngineType *engine_type = ED_view3d_engine_type(scene, v3d->shading.type);
|
||||
if (updated) {
|
||||
DRWUpdateContext drw_context = {nullptr};
|
||||
drw_context.bmain = bmain;
|
||||
drw_context.depsgraph = depsgraph;
|
||||
drw_context.scene = scene;
|
||||
drw_context.view_layer = view_layer;
|
||||
drw_context.region = region;
|
||||
drw_context.v3d = v3d;
|
||||
drw_context.engine_type = engine_type;
|
||||
DRW_notify_view_update(&drw_context);
|
||||
}
|
||||
|
||||
if (!updated) {
|
||||
continue;
|
||||
}
|
||||
|
||||
DRWUpdateContext drw_context = {nullptr};
|
||||
drw_context.bmain = bmain;
|
||||
drw_context.depsgraph = depsgraph;
|
||||
drw_context.scene = scene;
|
||||
drw_context.view_layer = view_layer;
|
||||
drw_context.region = region;
|
||||
drw_context.v3d = v3d;
|
||||
drw_context.engine_type = ED_view3d_engine_type(scene, v3d->shading.type);
|
||||
DRW_notify_view_update(&drw_context);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue