diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2013-02-27 13:58:40 +0400 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2013-02-27 13:58:40 +0400 |
commit | fefc6840368e60121fad886b05a72776b022a101 (patch) | |
tree | 4f5d26886576760f64cfc5b15a3703efa8a05ade /source/blender/blenkernel/intern/seqmodifier.c | |
parent | 3468eba71a30b9a2235a9f46e8998117b25c5baf (diff) |
Fix #34439: Strip modifier - Mask multiply failure
Diffstat (limited to 'source/blender/blenkernel/intern/seqmodifier.c')
-rw-r--r-- | source/blender/blenkernel/intern/seqmodifier.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/blenkernel/intern/seqmodifier.c b/source/blender/blenkernel/intern/seqmodifier.c index 9ea405ef636..a64a4895e9b 100644 --- a/source/blender/blenkernel/intern/seqmodifier.c +++ b/source/blender/blenkernel/intern/seqmodifier.c @@ -237,9 +237,9 @@ static void curves_apply_threaded(int width, int height, unsigned char *rect, fl rgb_uchar_to_float(t, mask_rect + pixel_index); - tempc[0] = pixel[0] * (1.0f - t[0]) + result[0] * t[0]; - tempc[1] = pixel[1] * (1.0f - t[1]) + result[1] * t[1]; - tempc[2] = pixel[2] * (1.0f - t[2]) + result[2] * t[2]; + tempc[0] = tempc[0] * (1.0f - t[0]) + result[0] * t[0]; + tempc[1] = tempc[1] * (1.0f - t[1]) + result[1] * t[1]; + tempc[2] = tempc[2] * (1.0f - t[2]) + result[2] * t[2]; } else { tempc[0] = result[0]; @@ -438,7 +438,7 @@ static void brightcontrast_apply_threaded(int width, int height, unsigned char * unsigned char *m = mask_rect + pixel_index; float t = (float) m[c] / 255.0f; - v = (float) pixel[c] * (1.0f - t) + v * t; + v = (float) pixel[c] / 255.0f * (1.0f - t) + v * t; } pixel[c] = FTOCHAR(v); |