diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-06-13 00:04:55 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-06-13 00:04:55 +0400 |
commit | e1241030db424ce10e9fee04076ff7e209eac98c (patch) | |
tree | ac8e1a81a81fa130e166366c6b93587e77e4188f /source/blender/compositor/operations/COM_AlphaOverPremultiplyOperation.cpp | |
parent | 7fec7070d7fcf7bde53768e555b40b57ef4a7552 (diff) |
yse BLI_math for the compositor in more places.
Diffstat (limited to 'source/blender/compositor/operations/COM_AlphaOverPremultiplyOperation.cpp')
-rw-r--r-- | source/blender/compositor/operations/COM_AlphaOverPremultiplyOperation.cpp | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/source/blender/compositor/operations/COM_AlphaOverPremultiplyOperation.cpp b/source/blender/compositor/operations/COM_AlphaOverPremultiplyOperation.cpp index 6cc33387917..db67f2e0406 100644 --- a/source/blender/compositor/operations/COM_AlphaOverPremultiplyOperation.cpp +++ b/source/blender/compositor/operations/COM_AlphaOverPremultiplyOperation.cpp @@ -38,16 +38,10 @@ void AlphaOverPremultiplyOperation::executePixel(float *outputValue, float x, fl /* Zero alpha values should still permit an add of RGB data */ if (inputOverColor[3]<0.0f) { - outputValue[0] = inputColor1[0]; - outputValue[1] = inputColor1[1]; - outputValue[2] = inputColor1[2]; - outputValue[3] = inputColor1[3]; + copy_v4_v4(outputValue, inputColor1); } else if (value[0] == 1.0f && inputOverColor[3] >= 1.0f) { - outputValue[0] = inputOverColor[0]; - outputValue[1] = inputOverColor[1]; - outputValue[2] = inputOverColor[2]; - outputValue[3] = inputOverColor[3]; + copy_v4_v4(outputValue, inputOverColor); } else { float mul = 1.0f - value[0]*inputOverColor[3]; |