Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/compositor/nodes/COM_ColorCorrectionNode.cpp')
-rw-r--r--source/blender/compositor/nodes/COM_ColorCorrectionNode.cpp14
1 files changed, 8 insertions, 6 deletions
diff --git a/source/blender/compositor/nodes/COM_ColorCorrectionNode.cpp b/source/blender/compositor/nodes/COM_ColorCorrectionNode.cpp
index a05abaf17d3..728b51b8dc1 100644
--- a/source/blender/compositor/nodes/COM_ColorCorrectionNode.cpp
+++ b/source/blender/compositor/nodes/COM_ColorCorrectionNode.cpp
@@ -29,16 +29,18 @@ ColorCorrectionNode::ColorCorrectionNode(bNode *editorNode) : Node(editorNode)
/* pass */
}
-void ColorCorrectionNode::convertToOperations(ExecutionSystem *graph, CompositorContext *context)
+void ColorCorrectionNode::convertToOperations(NodeConverter &converter, const CompositorContext &context) const
{
- ColorCorrectionOperation *operation = new ColorCorrectionOperation();
bNode *editorNode = getbNode();
- this->getInputSocket(0)->relinkConnections(operation->getInputSocket(0), 0, graph);
- this->getInputSocket(1)->relinkConnections(operation->getInputSocket(1), 1, graph);
- this->getOutputSocket(0)->relinkConnections(operation->getOutputSocket(0));
+
+ ColorCorrectionOperation *operation = new ColorCorrectionOperation();
operation->setData((NodeColorCorrection *)editorNode->storage);
operation->setRedChannelEnabled((editorNode->custom1 & 1) > 0);
operation->setGreenChannelEnabled((editorNode->custom1 & 2) > 0);
operation->setBlueChannelEnabled((editorNode->custom1 & 4) > 0);
- graph->addOperation(operation);
+ converter.addOperation(operation);
+
+ converter.mapInputSocket(getInputSocket(0), operation->getInputSocket(0));
+ converter.mapInputSocket(getInputSocket(1), operation->getInputSocket(1));
+ converter.mapOutputSocket(getOutputSocket(0), operation->getOutputSocket(0));
}