From 48997d2e40a74a83fb9edfb9de0999139392f634 Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Mon, 24 Oct 2016 12:26:12 +0200 Subject: Cycles: Cleanup, style --- intern/cycles/render/graph.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'intern/cycles/render/graph.cpp') diff --git a/intern/cycles/render/graph.cpp b/intern/cycles/render/graph.cpp index 131ec824be3..f6c83fb5c7e 100644 --- a/intern/cycles/render/graph.cpp +++ b/intern/cycles/render/graph.cpp @@ -148,8 +148,9 @@ void ShaderNode::attributes(Shader *shader, AttributeRequestSet *attributes) bool ShaderNode::equals(const ShaderNode& other) { - if (type != other.type || bump != other.bump) + if(type != other.type || bump != other.bump) { return false; + } assert(inputs.size() == other.inputs.size()); @@ -597,13 +598,13 @@ void ShaderGraph::deduplicate_nodes() /* Try to merge this node with another one. */ ShaderNode *merge_with = NULL; foreach(ShaderNode *other_node, candidates[node->type->name]) { - if (node != other_node && node->equals(*other_node)) { + if(node != other_node && node->equals(*other_node)) { merge_with = other_node; break; } } /* If found an equivalent, merge; otherwise keep node for later merges */ - if (merge_with != NULL) { + if(merge_with != NULL) { for(int i = 0; i < node->outputs.size(); ++i) { relink(node, node->outputs[i], merge_with->outputs[i]); } -- cgit v1.2.3