[Bf-blender-cvs] [9b034355e4a] master: Fix T70405: Geometry node not linking manual derivatives
Philipp Oeser
noreply at git.blender.org
Wed Oct 2 13:58:37 CEST 2019
Commit: 9b034355e4ad60041b871254acfcc8e4f4f6b39a
Author: Philipp Oeser
Date: Tue Oct 1 12:45:13 2019 +0200
Branches: master
https://developer.blender.org/rB9b034355e4ad60041b871254acfcc8e4f4f6b39a
Fix T70405: Geometry node not linking manual derivatives
Maniphest Tasks: T70405
Reviewed By: fclem
Differential Revision: https://developer.blender.org/D5954
===================================================================
M source/blender/nodes/shader/nodes/node_shader_geometry.c
===================================================================
diff --git a/source/blender/nodes/shader/nodes/node_shader_geometry.c b/source/blender/nodes/shader/nodes/node_shader_geometry.c
index d94141c3699..e22bbf90a94 100644
--- a/source/blender/nodes/shader/nodes/node_shader_geometry.c
+++ b/source/blender/nodes/shader/nodes/node_shader_geometry.c
@@ -47,7 +47,7 @@ static int node_shader_gpu_geometry(GPUMaterial *mat,
/* Opti: don't request orco if not needed. */
GPUNodeLink *orco_link = (!out[2].hasoutput) ? GPU_constant(val) : GPU_attribute(CD_ORCO, "");
- return GPU_stack_link(mat,
+ const bool success = GPU_stack_link(mat,
node,
"node_geometry",
in,
@@ -58,6 +58,13 @@ static int node_shader_gpu_geometry(GPUMaterial *mat,
GPU_builtin(GPU_OBJECT_MATRIX),
GPU_builtin(GPU_INVERSE_VIEW_MATRIX),
bary_link);
+
+ /* for each output */
+ for (int i = 0; sh_node_geometry_out[i].type != -1; i++) {
+ node_shader_gpu_bump_tex_coord(mat, node, &out[i].link);
+ }
+
+ return success;
}
/* node type definition */
More information about the Bf-blender-cvs
mailing list