diff options
author | Manuel Castilla <manzanillawork@gmail.com> | 2021-10-14 00:01:15 +0300 |
---|---|---|
committer | Manuel Castilla <manzanillawork@gmail.com> | 2021-10-14 00:41:14 +0300 |
commit | 1c42d4930a24d639b3aa561b9a8b4bbce05977e0 (patch) | |
tree | 68c2aae3fd5ae98b78708bea28c0b55d3f4fb5f0 /source/blender/compositor/operations/COM_ConvolutionEdgeFilterOperation.cc | |
parent | a2ee3c3a9f01f5cb2f05f1e84a1b6c1931d9d4a4 (diff) |
Cleanup: convert camelCase naming to snake_case in Compositor
To convert old code to the current convention and
use a single code style.
Diffstat (limited to 'source/blender/compositor/operations/COM_ConvolutionEdgeFilterOperation.cc')
-rw-r--r-- | source/blender/compositor/operations/COM_ConvolutionEdgeFilterOperation.cc | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/source/blender/compositor/operations/COM_ConvolutionEdgeFilterOperation.cc b/source/blender/compositor/operations/COM_ConvolutionEdgeFilterOperation.cc index 343cc32b625..7ba1f0bbe14 100644 --- a/source/blender/compositor/operations/COM_ConvolutionEdgeFilterOperation.cc +++ b/source/blender/compositor/operations/COM_ConvolutionEdgeFilterOperation.cc @@ -20,7 +20,7 @@ namespace blender::compositor { -void ConvolutionEdgeFilterOperation::executePixel(float output[4], int x, int y, void * /*data*/) +void ConvolutionEdgeFilterOperation::execute_pixel(float output[4], int x, int y, void * /*data*/) { float in1[4], in2[4], res1[4] = {0.0}, res2[4] = {0.0}; @@ -30,50 +30,50 @@ void ConvolutionEdgeFilterOperation::executePixel(float output[4], int x, int y, int y1 = y - 1; int y2 = y; int y3 = y + 1; - CLAMP(x1, 0, getWidth() - 1); - CLAMP(x2, 0, getWidth() - 1); - CLAMP(x3, 0, getWidth() - 1); - CLAMP(y1, 0, getHeight() - 1); - CLAMP(y2, 0, getHeight() - 1); - CLAMP(y3, 0, getHeight() - 1); + CLAMP(x1, 0, get_width() - 1); + CLAMP(x2, 0, get_width() - 1); + CLAMP(x3, 0, get_width() - 1); + CLAMP(y1, 0, get_height() - 1); + CLAMP(y2, 0, get_height() - 1); + CLAMP(y3, 0, get_height() - 1); float value[4]; - inputValueOperation_->read(value, x2, y2, nullptr); + input_value_operation_->read(value, x2, y2, nullptr); float mval = 1.0f - value[0]; - inputOperation_->read(in1, x1, y1, nullptr); + input_operation_->read(in1, x1, y1, nullptr); madd_v3_v3fl(res1, in1, filter_[0]); madd_v3_v3fl(res2, in1, filter_[0]); - inputOperation_->read(in1, x2, y1, nullptr); + input_operation_->read(in1, x2, y1, nullptr); madd_v3_v3fl(res1, in1, filter_[1]); madd_v3_v3fl(res2, in1, filter_[3]); - inputOperation_->read(in1, x3, y1, nullptr); + input_operation_->read(in1, x3, y1, nullptr); madd_v3_v3fl(res1, in1, filter_[2]); madd_v3_v3fl(res2, in1, filter_[6]); - inputOperation_->read(in1, x1, y2, nullptr); + input_operation_->read(in1, x1, y2, nullptr); madd_v3_v3fl(res1, in1, filter_[3]); madd_v3_v3fl(res2, in1, filter_[1]); - inputOperation_->read(in2, x2, y2, nullptr); + input_operation_->read(in2, x2, y2, nullptr); madd_v3_v3fl(res1, in2, filter_[4]); madd_v3_v3fl(res2, in2, filter_[4]); - inputOperation_->read(in1, x3, y2, nullptr); + input_operation_->read(in1, x3, y2, nullptr); madd_v3_v3fl(res1, in1, filter_[5]); madd_v3_v3fl(res2, in1, filter_[7]); - inputOperation_->read(in1, x1, y3, nullptr); + input_operation_->read(in1, x1, y3, nullptr); madd_v3_v3fl(res1, in1, filter_[6]); madd_v3_v3fl(res2, in1, filter_[2]); - inputOperation_->read(in1, x2, y3, nullptr); + input_operation_->read(in1, x2, y3, nullptr); madd_v3_v3fl(res1, in1, filter_[7]); madd_v3_v3fl(res2, in1, filter_[5]); - inputOperation_->read(in1, x3, y3, nullptr); + input_operation_->read(in1, x3, y3, nullptr); madd_v3_v3fl(res1, in1, filter_[8]); madd_v3_v3fl(res2, in1, filter_[8]); @@ -99,8 +99,8 @@ void ConvolutionEdgeFilterOperation::update_memory_buffer_partial(MemoryBuffer * Span<MemoryBuffer *> inputs) { const MemoryBuffer *image = inputs[IMAGE_INPUT_INDEX]; - const int last_x = getWidth() - 1; - const int last_y = getHeight() - 1; + const int last_x = get_width() - 1; + const int last_y = get_height() - 1; for (BuffersIterator<float> it = output->iterate_with(inputs, area); !it.is_end(); ++it) { const int left_offset = (it.x == 0) ? 0 : -image->elem_stride; const int right_offset = (it.x == last_x) ? 0 : image->elem_stride; |