[Bf-blender-cvs] [c6928843dc9] master: Fix Eevee shader node error when using both RGB and vector curve nodes
Brecht Van Lommel
noreply at git.blender.org
Sat Feb 15 20:33:02 CET 2020
Commit: c6928843dc9f07f4676048309d7a895ea0a1ef4e
Author: Brecht Van Lommel
Date: Sat Feb 15 17:44:54 2020 +0100
Branches: master
https://developer.blender.org/rBc6928843dc9f07f4676048309d7a895ea0a1ef4e
Fix Eevee shader node error when using both RGB and vector curve nodes
===================================================================
M source/blender/gpu/shaders/material/gpu_shader_material_vector_curves.glsl
===================================================================
diff --git a/source/blender/gpu/shaders/material/gpu_shader_material_vector_curves.glsl b/source/blender/gpu/shaders/material/gpu_shader_material_vector_curves.glsl
index 63e97e66c90..f6dec1b24e2 100644
--- a/source/blender/gpu/shaders/material/gpu_shader_material_vector_curves.glsl
+++ b/source/blender/gpu/shaders/material/gpu_shader_material_vector_curves.glsl
@@ -1,5 +1,5 @@
/* ext is vec4(in_x, in_dy, out_x, out_dy). */
-float curve_extrapolate(float x, float y, vec4 ext)
+float curve_vec_extrapolate(float x, float y, vec4 ext)
{
if (x < 0.0) {
return y + x * ext.y;
@@ -33,9 +33,9 @@ void curves_vec(float fac,
outvec.y = texture(curvemap, co.yw).y;
outvec.z = texture(curvemap, co.zw).z;
- outvec.x = curve_extrapolate(co.x, outvec.r, ext_x);
- outvec.y = curve_extrapolate(co.y, outvec.g, ext_y);
- outvec.z = curve_extrapolate(co.z, outvec.b, ext_z);
+ outvec.x = curve_vec_extrapolate(co.x, outvec.r, ext_x);
+ outvec.y = curve_vec_extrapolate(co.y, outvec.g, ext_y);
+ outvec.z = curve_vec_extrapolate(co.z, outvec.b, ext_z);
outvec = mix(vec, outvec, fac);
}
More information about the Bf-blender-cvs
mailing list