Blender Git Loki

Git Commits -> Revision 6a5d2f4

Revision 6a5d2f4 by Philipp Oeser (master)
October 29, 2020, 08:27 (GMT)
Fix blend_color_interpolate_byte returning wrong alpha in certain case

When the combined alpha [the 'tmp' variable having the mixfactor applied
already] - reached zero it was handled like a no-op (for the alpha as
well) and just copied the first color.

So e.g mixing 255/255/255/255 with 0/0/0/0 with a factor of 1.0 gave
alpha of 255, which looks wrong.

cases where tmp gets zero:
src1 alpha:0 src2 alpha:whatever mixfactor 0.0
src1 alpha:whatever src2 alpha:0 mixfactor 1.0
src1 alpha:0 src2 alpha:0 mixfactor whatever

Now set alpha to zero in that case.

ref T81914

Maniphest Tasks: T81914

Differential Revision: https://developer.blender.org/D9357

Commit Details:

Full Hash: 6a5d2f4ea2261528ae9d15c66852635b05743d97
Parent Commit: 01d02e7
Lines Changed: +1, -0

Tehnyt: Miika HämäläinenViimeksi p?ivitetty: 07.11.2014 14:18 MiikaH:n Sivut a.k.a. MiikaHweb | 2003-2020