From a3d774e4c94868c747230a200e0a41e371f547bd Mon Sep 17 00:00:00 2001 From: Thomas Dinges Date: Sun, 6 Dec 2015 23:47:38 +0100 Subject: Cycles: Fold Value and RGB node as well. This way, connecting Value or RGB node to e.g. a Math node will still allow folding. Note: The same should be done for the ConvertNode, but I leave that for another day. --- intern/cycles/render/nodes.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'intern/cycles/render/nodes.h') diff --git a/intern/cycles/render/nodes.h b/intern/cycles/render/nodes.h index 1fa4b67c6b9..51efbc37f38 100644 --- a/intern/cycles/render/nodes.h +++ b/intern/cycles/render/nodes.h @@ -485,6 +485,8 @@ class ValueNode : public ShaderNode { public: SHADER_NODE_CLASS(ValueNode) + bool constant_fold(ShaderOutput *socket, float3 *optimized_value); + float value; }; @@ -492,6 +494,8 @@ class ColorNode : public ShaderNode { public: SHADER_NODE_CLASS(ColorNode) + bool constant_fold(ShaderOutput *socket, float3 *optimized_value); + float3 value; }; -- cgit v1.2.3