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-23 04:21:22 +0300
committerCampbell Barton <ideasman42@gmail.com>2019-04-23 04:22:25 +0300
commit3302fbaeb1d5f58d926c06b6153ec5d6f1a9b0be (patch)
tree5be399e227415fef745bcdb2b7f20a578628718b /source/blender/compositor/operations/COM_MapValueOperation.cpp
parent64b4b719ebd5201d27aa25d7fa2d765eabded9b0 (diff)
Cleanup: style, use braces for compositor
Diffstat (limited to 'source/blender/compositor/operations/COM_MapValueOperation.cpp')
-rw-r--r--source/blender/compositor/operations/COM_MapValueOperation.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/source/blender/compositor/operations/COM_MapValueOperation.cpp b/source/blender/compositor/operations/COM_MapValueOperation.cpp
index d99a68a5e00..45104d11210 100644
--- a/source/blender/compositor/operations/COM_MapValueOperation.cpp
+++ b/source/blender/compositor/operations/COM_MapValueOperation.cpp
@@ -39,12 +39,16 @@ void MapValueOperation::executePixelSampled(float output[4],
this->m_inputOperation->readSampled(src, x, y, sampler);
TexMapping *texmap = this->m_settings;
float value = (src[0] + texmap->loc[0]) * texmap->size[0];
- if (texmap->flag & TEXMAP_CLIP_MIN)
- if (value < texmap->min[0])
+ if (texmap->flag & TEXMAP_CLIP_MIN) {
+ if (value < texmap->min[0]) {
value = texmap->min[0];
- if (texmap->flag & TEXMAP_CLIP_MAX)
- if (value > texmap->max[0])
+ }
+ }
+ if (texmap->flag & TEXMAP_CLIP_MAX) {
+ if (value > texmap->max[0]) {
value = texmap->max[0];
+ }
+ }
output[0] = value;
}