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/operations/COM_ConvolutionFilterOperation.cpp')
-rw-r--r--source/blender/compositor/operations/COM_ConvolutionFilterOperation.cpp30
1 files changed, 15 insertions, 15 deletions
diff --git a/source/blender/compositor/operations/COM_ConvolutionFilterOperation.cpp b/source/blender/compositor/operations/COM_ConvolutionFilterOperation.cpp
index 6c1e434ab41..fd593b39dcd 100644
--- a/source/blender/compositor/operations/COM_ConvolutionFilterOperation.cpp
+++ b/source/blender/compositor/operations/COM_ConvolutionFilterOperation.cpp
@@ -67,7 +67,7 @@ void ConvolutionFilterOperation::deinitExecution()
}
-void ConvolutionFilterOperation::executePixel(float *color, int x, int y, void *data)
+void ConvolutionFilterOperation::executePixel(float output[4], int x, int y, void *data)
{
float in1[4];
float in2[4];
@@ -87,30 +87,30 @@ void ConvolutionFilterOperation::executePixel(float *color, int x, int y, void *
this->m_inputValueOperation->read(value, x2, y2, NULL);
const float mval = 1.0f - value[0];
- zero_v4(color);
+ zero_v4(output);
this->m_inputOperation->read(in1, x1, y1, NULL);
- madd_v4_v4fl(color, in1, this->m_filter[0]);
+ madd_v4_v4fl(output, in1, this->m_filter[0]);
this->m_inputOperation->read(in1, x2, y1, NULL);
- madd_v4_v4fl(color, in1, this->m_filter[1]);
+ madd_v4_v4fl(output, in1, this->m_filter[1]);
this->m_inputOperation->read(in1, x3, y1, NULL);
- madd_v4_v4fl(color, in1, this->m_filter[2]);
+ madd_v4_v4fl(output, in1, this->m_filter[2]);
this->m_inputOperation->read(in1, x1, y2, NULL);
- madd_v4_v4fl(color, in1, this->m_filter[3]);
+ madd_v4_v4fl(output, in1, this->m_filter[3]);
this->m_inputOperation->read(in2, x2, y2, NULL);
- madd_v4_v4fl(color, in2, this->m_filter[4]);
+ madd_v4_v4fl(output, in2, this->m_filter[4]);
this->m_inputOperation->read(in1, x3, y2, NULL);
- madd_v4_v4fl(color, in1, this->m_filter[5]);
+ madd_v4_v4fl(output, in1, this->m_filter[5]);
this->m_inputOperation->read(in1, x1, y3, NULL);
- madd_v4_v4fl(color, in1, this->m_filter[6]);
+ madd_v4_v4fl(output, in1, this->m_filter[6]);
this->m_inputOperation->read(in1, x2, y3, NULL);
- madd_v4_v4fl(color, in1, this->m_filter[7]);
+ madd_v4_v4fl(output, in1, this->m_filter[7]);
this->m_inputOperation->read(in1, x3, y3, NULL);
- madd_v4_v4fl(color, in1, this->m_filter[8]);
+ madd_v4_v4fl(output, in1, this->m_filter[8]);
- color[0] = color[0] * value[0] + in2[0] * mval;
- color[1] = color[1] * value[0] + in2[1] * mval;
- color[2] = color[2] * value[0] + in2[2] * mval;
- color[3] = color[3] * value[0] + in2[3] * mval;
+ output[0] = output[0] * value[0] + in2[0] * mval;
+ output[1] = output[1] * value[0] + in2[1] * mval;
+ output[2] = output[2] * value[0] + in2[2] * mval;
+ output[3] = output[3] * value[0] + in2[3] * mval;
}
bool ConvolutionFilterOperation::determineDependingAreaOfInterest(rcti *input, ReadBufferOperation *readOperation, rcti *output)