[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [47993] trunk/blender/source/blender/ compositor/operations: code cleanup: spelling 'multiplyer' --> 'multiplier'
Campbell Barton
ideasman42 at gmail.com
Sat Jun 16 17:32:18 CEST 2012
Revision: 47993
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=47993
Author: campbellbarton
Date: 2012-06-16 15:32:18 +0000 (Sat, 16 Jun 2012)
Log Message:
-----------
code cleanup: spelling 'multiplyer' --> 'multiplier'
Modified Paths:
--------------
trunk/blender/source/blender/compositor/operations/COM_BokehBlurOperation.cpp
trunk/blender/source/blender/compositor/operations/COM_GaussianAlphaXBlurOperation.cpp
trunk/blender/source/blender/compositor/operations/COM_GaussianAlphaYBlurOperation.cpp
trunk/blender/source/blender/compositor/operations/COM_GaussianBokehBlurOperation.cpp
trunk/blender/source/blender/compositor/operations/COM_GaussianXBlurOperation.cpp
trunk/blender/source/blender/compositor/operations/COM_GaussianYBlurOperation.cpp
trunk/blender/source/blender/compositor/operations/COM_OpenCLKernels.cl.h
trunk/blender/source/blender/compositor/operations/COM_VariableSizeBokehBlurOperation.cpp
Modified: trunk/blender/source/blender/compositor/operations/COM_BokehBlurOperation.cpp
===================================================================
--- trunk/blender/source/blender/compositor/operations/COM_BokehBlurOperation.cpp 2012-06-16 15:15:05 UTC (rev 47992)
+++ trunk/blender/source/blender/compositor/operations/COM_BokehBlurOperation.cpp 2012-06-16 15:32:18 UTC (rev 47993)
@@ -79,7 +79,7 @@
inputBoundingBoxReader->read(tempBoundingBox, x, y, COM_PS_NEAREST, inputBuffers);
if (tempBoundingBox[0] > 0.0f) {
- float overallmultiplyer[4] = {0.0f, 0.0f, 0.0f, 0.0f};
+ float multiplier_accum[4] = {0.0f, 0.0f, 0.0f, 0.0f};
MemoryBuffer *inputBuffer = (MemoryBuffer *)data;
float *buffer = inputBuffer->getBuffer();
int bufferwidth = inputBuffer->getWidth();
@@ -109,14 +109,14 @@
float v = this->bokehMidY - (ny - y) * m;
inputBokehProgram->read(bokeh, u, v, COM_PS_NEAREST, inputBuffers);
madd_v4_v4v4(tempColor, bokeh, &buffer[bufferindex]);
- add_v4_v4(overallmultiplyer, bokeh);
+ add_v4_v4(multiplier_accum, bokeh);
bufferindex += offsetadd;
}
}
- color[0] = tempColor[0] * (1.0f / overallmultiplyer[0]);
- color[1] = tempColor[1] * (1.0f / overallmultiplyer[1]);
- color[2] = tempColor[2] * (1.0f / overallmultiplyer[2]);
- color[3] = tempColor[3] * (1.0f / overallmultiplyer[3]);
+ color[0] = tempColor[0] * (1.0f / multiplier_accum[0]);
+ color[1] = tempColor[1] * (1.0f / multiplier_accum[1]);
+ color[2] = tempColor[2] * (1.0f / multiplier_accum[2]);
+ color[3] = tempColor[3] * (1.0f / multiplier_accum[3]);
}
else {
inputProgram->read(color, x, y, COM_PS_NEAREST, inputBuffers);
Modified: trunk/blender/source/blender/compositor/operations/COM_GaussianAlphaXBlurOperation.cpp
===================================================================
--- trunk/blender/source/blender/compositor/operations/COM_GaussianAlphaXBlurOperation.cpp 2012-06-16 15:15:05 UTC (rev 47992)
+++ trunk/blender/source/blender/compositor/operations/COM_GaussianAlphaXBlurOperation.cpp 2012-06-16 15:32:18 UTC (rev 47993)
@@ -111,7 +111,7 @@
/* gauss */
float tempColor = 0.0f;
- float overallmultiplyer = 0.0f;
+ float multiplier_accum = 0.0f;
/* dilate */
float value_max = finv_test(buffer[(x * 4) + (y * 4 * bufferwidth)], do_invert); /* init with the current color to avoid unneeded lookups */
@@ -120,26 +120,26 @@
for (int nx = minx; nx < maxx; nx += step) {
const int index = (nx - x) + this->rad;
float value = finv_test(buffer[bufferindex], do_invert);
- float multiplyer;
+ float multiplier;
/* gauss */
{
- multiplyer = gausstab[index];
- tempColor += value * multiplyer;
- overallmultiplyer += multiplyer;
+ multiplier = gausstab[index];
+ tempColor += value * multiplier;
+ multiplier_accum += multiplier;
}
/* dilate - find most extreme color */
if (value > value_max) {
#if 0
- multiplyer = 1.0f - ((fabsf(x - nx)) / (float)this->rad);
+ multiplier = 1.0f - ((fabsf(x - nx)) / (float)this->rad);
#else
- multiplyer = distbuf_inv[index];
+ multiplier = distbuf_inv[index];
#endif
- value *= multiplyer;
+ value *= multiplier;
if (value > value_max) {
value_max = value;
- distfacinv_max = multiplyer;
+ distfacinv_max = multiplier;
}
}
@@ -147,7 +147,7 @@
}
/* blend between the max value and gauss blue - gives nice feather */
- const float value_gauss = tempColor / overallmultiplyer;
+ const float value_gauss = tempColor / multiplier_accum;
const float value_final = (value_max * distfacinv_max) + (value_gauss * (1.0f - distfacinv_max));
color[0] = finv_test(value_final, do_invert);
}
Modified: trunk/blender/source/blender/compositor/operations/COM_GaussianAlphaYBlurOperation.cpp
===================================================================
--- trunk/blender/source/blender/compositor/operations/COM_GaussianAlphaYBlurOperation.cpp 2012-06-16 15:15:05 UTC (rev 47992)
+++ trunk/blender/source/blender/compositor/operations/COM_GaussianAlphaYBlurOperation.cpp 2012-06-16 15:32:18 UTC (rev 47993)
@@ -107,7 +107,7 @@
/* gauss */
float tempColor = 0.0f;
- float overallmultiplyer = 0.0f;
+ float multiplier_accum = 0.0f;
/* dilate */
float value_max = finv_test(buffer[(x * 4) + (y * 4 * bufferwidth)], do_invert); /* init with the current color to avoid unneeded lookups */
@@ -118,33 +118,33 @@
const int index = (ny - y) + this->rad;
float value = finv_test(buffer[bufferindex], do_invert);
- float multiplyer;
+ float multiplier;
/* gauss */
{
- multiplyer = gausstab[index];
- tempColor += value * multiplyer;
- overallmultiplyer += multiplyer;
+ multiplier = gausstab[index];
+ tempColor += value * multiplier;
+ multiplier_accum += multiplier;
}
/* dilate - find most extreme color */
if (value > value_max) {
#if 0
- multiplyer = 1.0f - ((fabsf(y - ny)) / (float)this->rad);
+ multiplier = 1.0f - ((fabsf(y - ny)) / (float)this->rad);
#else
- multiplyer = distbuf_inv[index];
+ multiplier = distbuf_inv[index];
#endif
- value *= multiplyer;
+ value *= multiplier;
if (value > value_max) {
value_max = value;
- distfacinv_max = multiplyer;
+ distfacinv_max = multiplier;
}
}
}
/* blend between the max value and gauss blue - gives nice feather */
- const float value_gauss = tempColor / overallmultiplyer;
+ const float value_gauss = tempColor / multiplier_accum;
const float value_final = (value_max * distfacinv_max) + (value_gauss * (1.0f - distfacinv_max));
color[0] = finv_test(value_final, do_invert);
}
Modified: trunk/blender/source/blender/compositor/operations/COM_GaussianBokehBlurOperation.cpp
===================================================================
--- trunk/blender/source/blender/compositor/operations/COM_GaussianBokehBlurOperation.cpp 2012-06-16 15:15:05 UTC (rev 47992)
+++ trunk/blender/source/blender/compositor/operations/COM_GaussianBokehBlurOperation.cpp 2012-06-16 15:32:18 UTC (rev 47993)
@@ -115,7 +115,7 @@
tempColor[1] = 0;
tempColor[2] = 0;
tempColor[3] = 0;
- float overallmultiplyer = 0;
+ float multiplier_accum = 0;
MemoryBuffer *inputBuffer = (MemoryBuffer *)data;
float *buffer = inputBuffer->getBuffer();
int bufferwidth = inputBuffer->getWidth();
@@ -138,15 +138,15 @@
index = ((ny - y) + this->rady) * (this->radx * 2 + 1) + (minx - x + this->radx);
int bufferindex = ((minx - bufferstartx) * 4) + ((ny - bufferstarty) * 4 * bufferwidth);
for (int nx = minx; nx < maxx; nx += step) {
- const float multiplyer = gausstab[index];
- madd_v4_v4fl(tempColor, &buffer[bufferindex], multiplyer);
- overallmultiplyer += multiplyer;
+ const float multiplier = gausstab[index];
+ madd_v4_v4fl(tempColor, &buffer[bufferindex], multiplier);
+ multiplier_accum += multiplier;
index += step;
bufferindex += offsetadd;
}
}
- mul_v4_v4fl(color, tempColor, 1.0f / overallmultiplyer);
+ mul_v4_v4fl(color, tempColor, 1.0f / multiplier_accum);
}
void GaussianBokehBlurOperation::deinitExecution()
Modified: trunk/blender/source/blender/compositor/operations/COM_GaussianXBlurOperation.cpp
===================================================================
--- trunk/blender/source/blender/compositor/operations/COM_GaussianXBlurOperation.cpp 2012-06-16 15:15:05 UTC (rev 47992)
+++ trunk/blender/source/blender/compositor/operations/COM_GaussianXBlurOperation.cpp 2012-06-16 15:32:18 UTC (rev 47993)
@@ -77,7 +77,7 @@
tempColor[1] = 0;
tempColor[2] = 0;
tempColor[3] = 0;
- float overallmultiplyer = 0.0f;
+ float multiplier_accum = 0.0f;
MemoryBuffer *inputBuffer = (MemoryBuffer *)data;
float *buffer = inputBuffer->getBuffer();
int bufferwidth = inputBuffer->getWidth();
@@ -99,12 +99,12 @@
int bufferindex = ((minx - bufferstartx) * 4) + ((miny - bufferstarty) * 4 * bufferwidth);
for (int nx = minx; nx < maxx; nx += step) {
index = (nx - x) + this->rad;
- const float multiplyer = gausstab[index];
- madd_v4_v4fl(tempColor, &buffer[bufferindex], multiplyer);
- overallmultiplyer += multiplyer;
+ const float multiplier = gausstab[index];
+ madd_v4_v4fl(tempColor, &buffer[bufferindex], multiplier);
+ multiplier_accum += multiplier;
bufferindex += offsetadd;
}
- mul_v4_v4fl(color, tempColor, 1.0f / overallmultiplyer);
+ mul_v4_v4fl(color, tempColor, 1.0f / multiplier_accum);
}
void GaussianXBlurOperation::deinitExecution()
Modified: trunk/blender/source/blender/compositor/operations/COM_GaussianYBlurOperation.cpp
===================================================================
--- trunk/blender/source/blender/compositor/operations/COM_GaussianYBlurOperation.cpp 2012-06-16 15:15:05 UTC (rev 47992)
+++ trunk/blender/source/blender/compositor/operations/COM_GaussianYBlurOperation.cpp 2012-06-16 15:32:18 UTC (rev 47993)
@@ -74,7 +74,7 @@
tempColor[1] = 0;
tempColor[2] = 0;
tempColor[3] = 0;
- float overallmultiplyer = 0;
+ float multiplier_accum = 0;
MemoryBuffer *inputBuffer = (MemoryBuffer *)data;
float *buffer = inputBuffer->getBuffer();
int bufferwidth = inputBuffer->getWidth();
@@ -95,11 +95,11 @@
for (int ny = miny; ny < maxy; ny += step) {
index = (ny - y) + this->rad;
int bufferindex = ((minx - bufferstartx) * 4) + ((ny - bufferstarty) * 4 * bufferwidth);
- const float multiplyer = gausstab[index];
- madd_v4_v4fl(tempColor, &buffer[bufferindex], multiplyer);
- overallmultiplyer += multiplyer;
+ const float multiplier = gausstab[index];
+ madd_v4_v4fl(tempColor, &buffer[bufferindex], multiplier);
+ multiplier_accum += multiplier;
}
- mul_v4_v4fl(color, tempColor, 1.0f / overallmultiplyer);
+ mul_v4_v4fl(color, tempColor, 1.0f / multiplier_accum);
}
void GaussianYBlurOperation::deinitExecution()
Modified: trunk/blender/source/blender/compositor/operations/COM_OpenCLKernels.cl.h
===================================================================
--- trunk/blender/source/blender/compositor/operations/COM_OpenCLKernels.cl.h 2012-06-16 15:15:05 UTC (rev 47992)
+++ trunk/blender/source/blender/compositor/operations/COM_OpenCLKernels.cl.h 2012-06-16 15:32:18 UTC (rev 47993)
@@ -16,7 +16,7 @@
" coords += offset;\n" \
" float tempBoundingBox;\n" \
" float4 color = {0.0f,0.0f,0.0f,0.0f};\n" \
-" float4 multiplyer = {0.0f,0.0f,0.0f,0.0f};\n" \
+" float4 multiplier = {0.0f,0.0f,0.0f,0.0f};\n" \
" float4 bokeh;\n" \
" const float radius2 = radius*2.0f;\n" \
@@ Diff output truncated at 10240 characters. @@
More information about the Bf-blender-cvs
mailing list