diff options
author | Hans Goudey <h.goudey@me.com> | 2021-07-19 02:29:49 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2021-07-19 02:29:49 +0300 |
commit | db384d4df6c0aca209554573e2fe85efa9f0cd0d (patch) | |
tree | ccc35afe7000942113d8f700ae5f4fdc3bf61bfe /source/blender/compositor/nodes/COM_IDMaskNode.cc | |
parent | 20ddb64207a1b06df56b6666574843fa6d9b3374 (diff) | |
parent | 83883ae66ad3231840d483ff091727b33d2f355b (diff) |
Merge branch 'master' into temp-geometry-nodes-curve-sample
Diffstat (limited to 'source/blender/compositor/nodes/COM_IDMaskNode.cc')
-rw-r--r-- | source/blender/compositor/nodes/COM_IDMaskNode.cc | 26 |
1 files changed, 21 insertions, 5 deletions
diff --git a/source/blender/compositor/nodes/COM_IDMaskNode.cc b/source/blender/compositor/nodes/COM_IDMaskNode.cc index 9798dabd035..b51e79f2dea 100644 --- a/source/blender/compositor/nodes/COM_IDMaskNode.cc +++ b/source/blender/compositor/nodes/COM_IDMaskNode.cc @@ -17,9 +17,9 @@ */ #include "COM_IDMaskNode.h" -#include "COM_AntiAliasOperation.h" #include "COM_ExecutionSystem.h" #include "COM_IDMaskOperation.h" +#include "COM_SMAAOperation.h" namespace blender::compositor { @@ -42,11 +42,27 @@ void IDMaskNode::convertToOperations(NodeConverter &converter, converter.mapOutputSocket(getOutputSocket(0), operation->getOutputSocket(0)); } else { - AntiAliasOperation *antiAliasOperation = new AntiAliasOperation(); - converter.addOperation(antiAliasOperation); + SMAAEdgeDetectionOperation *operation1 = nullptr; - converter.addLink(operation->getOutputSocket(), antiAliasOperation->getInputSocket(0)); - converter.mapOutputSocket(getOutputSocket(0), antiAliasOperation->getOutputSocket(0)); + operation1 = new SMAAEdgeDetectionOperation(); + converter.addOperation(operation1); + + converter.addLink(operation->getOutputSocket(0), operation1->getInputSocket(0)); + + /* Blending Weight Calculation Pixel Shader (Second Pass). */ + SMAABlendingWeightCalculationOperation *operation2 = + new SMAABlendingWeightCalculationOperation(); + converter.addOperation(operation2); + + converter.addLink(operation1->getOutputSocket(), operation2->getInputSocket(0)); + + /* Neighborhood Blending Pixel Shader (Third Pass). */ + SMAANeighborhoodBlendingOperation *operation3 = new SMAANeighborhoodBlendingOperation(); + converter.addOperation(operation3); + + converter.addLink(operation->getOutputSocket(0), operation3->getInputSocket(0)); + converter.addLink(operation2->getOutputSocket(), operation3->getInputSocket(1)); + converter.mapOutputSocket(getOutputSocket(0), operation3->getOutputSocket()); } } |