From 6a1d82490e49d1f5d73b5082516b087d44010fb8 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Tue, 26 Jun 2012 01:22:05 +0000 Subject: use m_ prefix for compositor class members (all compositor operations). --- .../operations/COM_EllipseMaskOperation.cpp | 46 +++++++++++----------- 1 file changed, 23 insertions(+), 23 deletions(-) (limited to 'source/blender/compositor/operations/COM_EllipseMaskOperation.cpp') diff --git a/source/blender/compositor/operations/COM_EllipseMaskOperation.cpp b/source/blender/compositor/operations/COM_EllipseMaskOperation.cpp index 0beacd02738..1aa1b89ee76 100644 --- a/source/blender/compositor/operations/COM_EllipseMaskOperation.cpp +++ b/source/blender/compositor/operations/COM_EllipseMaskOperation.cpp @@ -29,19 +29,19 @@ EllipseMaskOperation::EllipseMaskOperation() : NodeOperation() this->addInputSocket(COM_DT_VALUE); this->addInputSocket(COM_DT_VALUE); this->addOutputSocket(COM_DT_VALUE); - this->inputMask = NULL; - this->inputValue = NULL; - this->cosine = 0.0f; - this->sine = 0.0f; + this->m_inputMask = NULL; + this->m_inputValue = NULL; + this->m_cosine = 0.0f; + this->m_sine = 0.0f; } void EllipseMaskOperation::initExecution() { - this->inputMask = this->getInputSocketReader(0); - this->inputValue = this->getInputSocketReader(1); - const double rad = DEG2RAD((double)this->data->rotation); - this->cosine = cos(rad); - this->sine = sin(rad); - this->aspectRatio = ((float)this->getWidth()) / this->getHeight(); + this->m_inputMask = this->getInputSocketReader(0); + this->m_inputValue = this->getInputSocketReader(1); + const double rad = DEG2RAD((double)this->m_data->rotation); + this->m_cosine = cos(rad); + this->m_sine = sin(rad); + this->m_aspectRatio = ((float)this->getWidth()) / this->getHeight(); } void EllipseMaskOperation::executePixel(float *color, float x, float y, PixelSampler sampler, MemoryBuffer *inputBuffers[]) @@ -52,26 +52,26 @@ void EllipseMaskOperation::executePixel(float *color, float x, float y, PixelSam float rx = x / this->getWidth(); float ry = y / this->getHeight(); - const float dy = (ry - this->data->y) / this->aspectRatio; - const float dx = rx - this->data->x; - rx = this->data->x + (this->cosine * dx + this->sine * dy); - ry = this->data->y + (-this->sine * dx + this->cosine * dy); + const float dy = (ry - this->m_data->y) / this->m_aspectRatio; + const float dx = rx - this->m_data->x; + rx = this->m_data->x + (this->m_cosine * dx + this->m_sine * dy); + ry = this->m_data->y + (-this->m_sine * dx + this->m_cosine * dy); - this->inputMask->read(inputMask, x, y, sampler, inputBuffers); - this->inputValue->read(inputValue, x, y, sampler, inputBuffers); + this->m_inputMask->read(inputMask, x, y, sampler, inputBuffers); + this->m_inputValue->read(inputValue, x, y, sampler, inputBuffers); - const float halfHeight = (this->data->height) / 2.0f; - const float halfWidth = this->data->width / 2.0f; - float sx = rx - this->data->x; + const float halfHeight = (this->m_data->height) / 2.0f; + const float halfWidth = this->m_data->width / 2.0f; + float sx = rx - this->m_data->x; sx *= sx; const float tx = halfWidth * halfWidth; - float sy = ry - this->data->y; + float sy = ry - this->m_data->y; sy *= sy; const float ty = halfHeight * halfHeight; bool inside = ((sx / tx) + (sy / ty)) < 1.0f; - switch (this->maskType) { + switch (this->m_maskType) { case CMP_NODE_MASKTYPE_ADD: if (inside) { color[0] = max(inputMask[0], inputValue[0]); @@ -117,7 +117,7 @@ void EllipseMaskOperation::executePixel(float *color, float x, float y, PixelSam void EllipseMaskOperation::deinitExecution() { - this->inputMask = NULL; - this->inputValue = NULL; + this->m_inputMask = NULL; + this->m_inputValue = NULL; } -- cgit v1.2.3