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:
authorSergey Sharybin <sergey.vfx@gmail.com>2016-05-20 17:58:40 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2016-05-20 17:58:56 +0300
commitca8419ed6efa3a764ea1f51d745bfc0ad3e64246 (patch)
treeec352963eb3923b6e1b627225cfe565d217c9fc3 /source/blender/nodes
parenta5a05fc291ab8e024e3ff6bf9cd63733c7687f86 (diff)
Support Cycles magic texture in GLSL viewport
Diffstat (limited to 'source/blender/nodes')
-rw-r--r--source/blender/nodes/shader/nodes/node_shader_tex_magic.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/nodes/shader/nodes/node_shader_tex_magic.c b/source/blender/nodes/shader/nodes/node_shader_tex_magic.c
index 80904e376bc..8700d7954e7 100644
--- a/source/blender/nodes/shader/nodes/node_shader_tex_magic.c
+++ b/source/blender/nodes/shader/nodes/node_shader_tex_magic.c
@@ -57,8 +57,10 @@ static int node_shader_gpu_tex_magic(GPUMaterial *mat, bNode *node, bNodeExecDat
NodeTexMagic *tex = (NodeTexMagic *)node->storage;
float depth = tex->depth;
- if (!in[0].link)
+ if (!in[0].link) {
in[0].link = GPU_attribute(CD_ORCO, "");
+ GPU_link(mat, "generated_from_orco", in[0].link, &in[0].link);
+ }
node_shader_gpu_tex_mapping(mat, node, in, out);