[Bf-blender-cvs] [031dcbf15be] master: Fix crash in some Eevee shader node setups after vector math node changes
Brecht Van Lommel
noreply at git.blender.org
Sat Feb 15 20:33:00 CET 2020
Commit: 031dcbf15be5eef3d76488949ccebbf0872b1086
Author: Brecht Van Lommel
Date: Sat Feb 15 17:37:05 2020 +0100
Branches: master
https://developer.blender.org/rB031dcbf15be5eef3d76488949ccebbf0872b1086
Fix crash in some Eevee shader node setups after vector math node changes
===================================================================
M source/blender/nodes/shader/nodes/node_shader_geometry.c
M source/blender/nodes/shader/nodes/node_shader_tex_coord.c
===================================================================
diff --git a/source/blender/nodes/shader/nodes/node_shader_geometry.c b/source/blender/nodes/shader/nodes/node_shader_geometry.c
index d24d83dbc8a..6b23fec5f18 100644
--- a/source/blender/nodes/shader/nodes/node_shader_geometry.c
+++ b/source/blender/nodes/shader/nodes/node_shader_geometry.c
@@ -68,8 +68,14 @@ static int node_shader_gpu_geometry(GPUMaterial *mat,
* The resulting vector can still be a bit wrong but not as much.
* (see T70644) */
if (node->branch_tag != 0 && ELEM(i, 1, 2, 4)) {
- GPU_link(
- mat, "vector_math_normalize", out[i].link, out[i].link, out[i].link, &out[i].link, NULL);
+ GPU_link(mat,
+ "vector_math_normalize",
+ out[i].link,
+ out[i].link,
+ out[i].link,
+ out[i].link,
+ &out[i].link,
+ NULL);
}
}
diff --git a/source/blender/nodes/shader/nodes/node_shader_tex_coord.c b/source/blender/nodes/shader/nodes/node_shader_tex_coord.c
index 8bb17acc4d3..3c1a2280aae 100644
--- a/source/blender/nodes/shader/nodes/node_shader_tex_coord.c
+++ b/source/blender/nodes/shader/nodes/node_shader_tex_coord.c
@@ -68,8 +68,14 @@ static int node_shader_gpu_tex_coord(GPUMaterial *mat,
* The resulting vector can still be a bit wrong but not as much.
* (see T70644) */
if (node->branch_tag != 0 && ELEM(i, 1, 6)) {
- GPU_link(
- mat, "vector_math_normalize", out[i].link, out[i].link, out[i].link, &out[i].link, NULL);
+ GPU_link(mat,
+ "vector_math_normalize",
+ out[i].link,
+ out[i].link,
+ out[i].link,
+ out[i].link,
+ &out[i].link,
+ NULL);
}
}
More information about the Bf-blender-cvs
mailing list