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:
authorCampbell Barton <ideasman42@gmail.com>2019-04-17 07:17:24 +0300
committerCampbell Barton <ideasman42@gmail.com>2019-04-17 07:21:24 +0300
commite12c08e8d170b7ca40f204a5b0423c23a9fbc2c1 (patch)
tree8cf3453d12edb177a218ef8009357518ec6cab6a /source/blender/compositor/nodes/COM_ColorBalanceNode.cpp
parentb3dabc200a4b0399ec6b81f2ff2730d07b44fcaa (diff)
ClangFormat: apply to source, most of intern
Apply clang format as proposed in T53211. For details on usage and instructions for migrating branches without conflicts, see: https://wiki.blender.org/wiki/Tools/ClangFormat
Diffstat (limited to 'source/blender/compositor/nodes/COM_ColorBalanceNode.cpp')
-rw-r--r--source/blender/compositor/nodes/COM_ColorBalanceNode.cpp69
1 files changed, 35 insertions, 34 deletions
diff --git a/source/blender/compositor/nodes/COM_ColorBalanceNode.cpp b/source/blender/compositor/nodes/COM_ColorBalanceNode.cpp
index 4fab93c07a1..64503ca306b 100644
--- a/source/blender/compositor/nodes/COM_ColorBalanceNode.cpp
+++ b/source/blender/compositor/nodes/COM_ColorBalanceNode.cpp
@@ -25,48 +25,49 @@
ColorBalanceNode::ColorBalanceNode(bNode *editorNode) : Node(editorNode)
{
- /* pass */
+ /* pass */
}
-void ColorBalanceNode::convertToOperations(NodeConverter &converter, const CompositorContext &/*context*/) const
+void ColorBalanceNode::convertToOperations(NodeConverter &converter,
+ const CompositorContext & /*context*/) const
{
- bNode *node = this->getbNode();
- NodeColorBalance *n = (NodeColorBalance *)node->storage;
+ bNode *node = this->getbNode();
+ NodeColorBalance *n = (NodeColorBalance *)node->storage;
- NodeInput *inputSocket = this->getInputSocket(0);
- NodeInput *inputImageSocket = this->getInputSocket(1);
- NodeOutput *outputSocket = this->getOutputSocket(0);
+ NodeInput *inputSocket = this->getInputSocket(0);
+ NodeInput *inputImageSocket = this->getInputSocket(1);
+ NodeOutput *outputSocket = this->getOutputSocket(0);
- NodeOperation *operation;
- if (node->custom1 == 0) {
- ColorBalanceLGGOperation *operationLGG = new ColorBalanceLGGOperation();
+ NodeOperation *operation;
+ if (node->custom1 == 0) {
+ ColorBalanceLGGOperation *operationLGG = new ColorBalanceLGGOperation();
- float lift_lgg[3], gamma_inv[3];
- for (int c = 0; c < 3; c++) {
- lift_lgg[c] = 2.0f - n->lift[c];
- gamma_inv[c] = (n->gamma[c] != 0.0f) ? 1.0f / n->gamma[c] : 1000000.0f;
- }
+ float lift_lgg[3], gamma_inv[3];
+ for (int c = 0; c < 3; c++) {
+ lift_lgg[c] = 2.0f - n->lift[c];
+ gamma_inv[c] = (n->gamma[c] != 0.0f) ? 1.0f / n->gamma[c] : 1000000.0f;
+ }
- operationLGG->setGain(n->gain);
- operationLGG->setLift(lift_lgg);
- operationLGG->setGammaInv(gamma_inv);
- operation = operationLGG;
- }
- else {
- ColorBalanceASCCDLOperation *operationCDL = new ColorBalanceASCCDLOperation();
+ operationLGG->setGain(n->gain);
+ operationLGG->setLift(lift_lgg);
+ operationLGG->setGammaInv(gamma_inv);
+ operation = operationLGG;
+ }
+ else {
+ ColorBalanceASCCDLOperation *operationCDL = new ColorBalanceASCCDLOperation();
- float offset[3];
- copy_v3_fl(offset, n->offset_basis);
- add_v3_v3(offset, n->offset);
+ float offset[3];
+ copy_v3_fl(offset, n->offset_basis);
+ add_v3_v3(offset, n->offset);
- operationCDL->setOffset(offset);
- operationCDL->setPower(n->power);
- operationCDL->setSlope(n->slope);
- operation = operationCDL;
- }
- converter.addOperation(operation);
+ operationCDL->setOffset(offset);
+ operationCDL->setPower(n->power);
+ operationCDL->setSlope(n->slope);
+ operation = operationCDL;
+ }
+ converter.addOperation(operation);
- converter.mapInputSocket(inputSocket, operation->getInputSocket(0));
- converter.mapInputSocket(inputImageSocket, operation->getInputSocket(1));
- converter.mapOutputSocket(outputSocket, operation->getOutputSocket(0));
+ converter.mapInputSocket(inputSocket, operation->getInputSocket(0));
+ converter.mapInputSocket(inputImageSocket, operation->getInputSocket(1));
+ converter.mapOutputSocket(outputSocket, operation->getOutputSocket(0));
}