Fix: GPU compositor always returns first view
The experimental GPU compositor always returned the first view in multi-view rendering. This patch fixes that by also checking for the view name of the context when searching for the appropriate pass.
This commit is contained in:
@@ -231,8 +231,7 @@ class Context : public realtime_compositor::Context {
|
||||
if (view_layer) {
|
||||
RenderLayer *rl = RE_GetRenderLayer(rr, view_layer->name);
|
||||
if (rl) {
|
||||
RenderPass *rpass = (RenderPass *)BLI_findstring(
|
||||
&rl->passes, pass_name, offsetof(RenderPass, name));
|
||||
RenderPass *rpass = RE_pass_find_by_name(rl, pass_name, get_view_name().data());
|
||||
|
||||
if (rpass && rpass->ibuf && rpass->ibuf->float_buffer.data) {
|
||||
input_texture = RE_pass_ensure_gpu_texture_cache(re, rpass);
|
||||
|
||||
Reference in New Issue
Block a user