Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@gmail.com>2016-03-06 08:54:40 +0300
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2016-03-06 08:55:20 +0300
commit6bfd88acd9498bb068bde7ab047a593254b96a88 (patch)
tree54112435738037ab9272609731592f1fae1946ff /source/blender/nodes
parent7499fcf1770ed4fd61d874ab9bb706879ba83b35 (diff)
Fix T47670: cycles GLSL incorrect normal map node.
Diffstat (limited to 'source/blender/nodes')
-rw-r--r--source/blender/nodes/shader/nodes/node_shader_normal_map.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source/blender/nodes/shader/nodes/node_shader_normal_map.c b/source/blender/nodes/shader/nodes/node_shader_normal_map.c
index 097a4928dd0..13bf2a0fe43 100644
--- a/source/blender/nodes/shader/nodes/node_shader_normal_map.c
+++ b/source/blender/nodes/shader/nodes/node_shader_normal_map.c
@@ -48,7 +48,10 @@ static void node_shader_init_normal_map(bNodeTree *UNUSED(ntree), bNode *node)
static int gpu_shader_normal_map(GPUMaterial *mat, bNode *UNUSED(node), bNodeExecData *UNUSED(execdata), GPUNodeStack *in, GPUNodeStack *out)
{
- return GPU_stack_link(mat, "node_normal_map", in, out, GPU_builtin(GPU_VIEW_NORMAL));
+ GPUNodeLink *normal;
+ GPU_link(mat, "direction_transform_m4v3", GPU_builtin(GPU_VIEW_NORMAL), GPU_builtin(GPU_INVERSE_VIEW_MATRIX), &normal);
+
+ return GPU_stack_link(mat, "node_normal_map", in, out, normal);
}
/* node type definition */