Skip to content

Commit 367ade5

Browse files
committed
Address clean up notes
1 parent d85d34b commit 367ade5

2 files changed

Lines changed: 2 additions & 3 deletions

File tree

source/MaterialXGenOsl/OslShaderGenerator.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -166,8 +166,7 @@ ShaderPtr OslShaderGenerator::generate(const string& name, ElementPtr element, G
166166
for (size_t i = 0; i < outputs.size(); ++i)
167167
{
168168
const ShaderGraphOutputSocket* outputSocket = graph.getOutputSocket(i);
169-
const string result = getUpstreamResult(outputSocket, context);
170-
emitLine(outputSocket->getVariable() + " = " + result, stage);
169+
emitLine(outputSocket->getVariable() + " = " + getUpstreamResult(outputSocket, context), stage);
171170
}
172171

173172
// End shader body

source/MaterialXGenShader/ShaderGraph.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -789,7 +789,7 @@ ShaderNode* ShaderGraph::inlineNodeBeforeOutput(ShaderGraphOutputSocket* output,
789789
InputPtr nodeDefInput = nullptr;
790790
if (!inputName.empty())
791791
{
792-
// only look for the input if we are given an inputName - its valid to insert the node
792+
// Only look for the input if we are given an inputName. It's valid to insert the node
793793
// without any upstream connection, and so an input name is not required.
794794
nodeDefInput = nodeDef->getInput(inputName);
795795
if (!nodeDefInput)

0 commit comments

Comments
 (0)