Commit: f2728939df31dba0e243a1657afa5c1682cccc32
Author: Lukas Stockner
Date:   Tue Aug 8 23:00:02 2017 +0200
Branches: master
https://developer.blender.org/rBf2728939df31dba0e243a1657afa5c1682cccc32

Fix T52280: The Image node in Compositing can't read Z buffer of openEXR in 2.79

As part of the fix for T51587, I removed the Depth output for non-Multilayer
images since it seemed weird that PNGs etc. that don't have a Z pass still get
a socket for it.
However, I forgot about non-multilayer EXRs, which are a special case that can
actually have a Z pass.

Therefore, this commit brings back the Depth output for non-multilayer images
just like it was in 2.78.

===================================================================

M       source/blender/nodes/composite/nodes/node_composite_image.c

===================================================================

diff --git a/source/blender/nodes/composite/nodes/node_composite_image.c 
b/source/blender/nodes/composite/nodes/node_composite_image.c
index 8139e29bade..a95c3233132 100644
--- a/source/blender/nodes/composite/nodes/node_composite_image.c
+++ b/source/blender/nodes/composite/nodes/node_composite_image.c
@@ -178,6 +178,9 @@ static void cmp_node_image_create_outputs(bNodeTree *ntree, 
bNode *node, LinkNod
        cmp_node_image_add_pass_output(ntree, node, "Alpha", 
RE_PASSNAME_COMBINED, -1, SOCK_FLOAT, false, available_sockets, &prev_index);
 
        if (ima) {
+               if (!ima->rr) {
+                       cmp_node_image_add_pass_output(ntree, node, 
RE_PASSNAME_Z, RE_PASSNAME_Z, -1, SOCK_FLOAT, false, available_sockets, 
&prev_index);
+               }
                BKE_image_release_ibuf(ima, ibuf, NULL);
        }
 }

_______________________________________________
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to