diff options
author | Lukas Tönne <lukas.toenne@gmail.com> | 2014-09-23 18:57:11 +0400 |
---|---|---|
committer | Lukas Tönne <lukas.toenne@gmail.com> | 2014-09-23 18:59:12 +0400 |
commit | 82c90a44c2db62fbf14dd23481ae2f43b4322667 (patch) | |
tree | d8838c493e07e90d076b0f7ca4eee2bb1d8a4db0 | |
parent | ed4075cb3410f7e51ea766ab771eee690e3da71c (diff) |
Fix T41921: MapUV node alpha setting broken.
The UV values includes the image width/height now. To restore the
previous method as close as possible (even though it is not documented
anywhere how this is supposed to work), we have to ignore this scaling.
-rw-r--r-- | source/blender/compositor/operations/COM_MapUVOperation.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/compositor/operations/COM_MapUVOperation.cpp b/source/blender/compositor/operations/COM_MapUVOperation.cpp index 87ad1d6afa4..6bf730253e7 100644 --- a/source/blender/compositor/operations/COM_MapUVOperation.cpp +++ b/source/blender/compositor/operations/COM_MapUVOperation.cpp @@ -62,7 +62,7 @@ void MapUVOperation::executePixelSampled(float output[4], float x, float y, Pixe */ float du = len_v2(deriv[0]); float dv = len_v2(deriv[1]); - float factor = 1.0f - threshold * (du + dv); + float factor = 1.0f - threshold * (du / m_inputColorProgram->getWidth() + dv / m_inputColorProgram->getHeight()); if (factor < 0.f) alpha = 0.f; else alpha *= factor; |