From e5618725fd1ebdf558e963d959eb3950b5a9874c Mon Sep 17 00:00:00 2001 From: OmarSquircleArt Date: Sun, 18 Aug 2019 11:16:04 +0200 Subject: Shading: Refactor Math node and use dynamic inputs. - Implement dynamic inputs. The second input is now unavailable in single operand math operators. - Reimplemenet the clamp option using graph expansion for Cycles. - Clean up code and unify naming between Blender and Cycles. - Remove unused code. Reviewers: brecht Differential Revision: https://developer.blender.org/D5481 --- intern/cycles/render/nodes.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'intern/cycles/render/nodes.h') diff --git a/intern/cycles/render/nodes.h b/intern/cycles/render/nodes.h index d4708adf9af..514ab3db8eb 100644 --- a/intern/cycles/render/nodes.h +++ b/intern/cycles/render/nodes.h @@ -1260,11 +1260,12 @@ class MathNode : public ShaderNode { { return NODE_GROUP_LEVEL_1; } + void expand(ShaderGraph *graph); void constant_fold(const ConstantFolder &folder); float value1; float value2; - NodeMath type; + NodeMathType type; bool use_clamp; }; -- cgit v1.2.3