diff options
Diffstat (limited to 'source/blender/compositor/operations/COM_BrightnessOperation.cpp')
-rw-r--r-- | source/blender/compositor/operations/COM_BrightnessOperation.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/source/blender/compositor/operations/COM_BrightnessOperation.cpp b/source/blender/compositor/operations/COM_BrightnessOperation.cpp index bb481f71cc1..a62470e5b1d 100644 --- a/source/blender/compositor/operations/COM_BrightnessOperation.cpp +++ b/source/blender/compositor/operations/COM_BrightnessOperation.cpp @@ -53,13 +53,11 @@ void BrightnessOperation::executePixel(float* color, float x, float y, PixelSamp * (http://visca.com/ffactory/archives/5-99/msg00021.html) * Extracted of OpenCV demhist.c */ - if( contrast > 0 ) - { + if (contrast > 0) { a = 1.0f / a; b = a * (brightness - delta); } - else - { + else { delta *= -1; b = a * (brightness + delta); } |