[Bf-blender-cvs] [fdee84fd567] blender2.7: Fix T61733: wrong alpha for sequencer screen, multiply, .. blend modes.

John Quillan noreply at git.blender.org
Thu Feb 21 13:30:19 CET 2019


Commit: fdee84fd567a5bb87ee5c4ec0abfd8c79aed4801
Author: John Quillan
Date:   Thu Feb 21 13:26:22 2019 +0100
Branches: blender2.7
https://developer.blender.org/rBfdee84fd567a5bb87ee5c4ec0abfd8c79aed4801

Fix T61733: wrong alpha for sequencer screen, multiply, .. blend modes.

It was copying the alpha from the foreground instead of background image,
which is not usually what is needed and inconsistent with the compositor.

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

===================================================================

M	source/blender/blenkernel/intern/seqeffects.c

===================================================================

diff --git a/source/blender/blenkernel/intern/seqeffects.c b/source/blender/blenkernel/intern/seqeffects.c
index 788935b12e6..57480006439 100644
--- a/source/blender/blenkernel/intern/seqeffects.c
+++ b/source/blender/blenkernel/intern/seqeffects.c
@@ -1318,11 +1318,11 @@ BLI_INLINE void apply_blend_function_byte(
 	rt = out;
 	while (y--) {
 		for (x = xo; x > 0; x--) {
-			achannel = rt2[3];
-			rt2[3] = (unsigned int) achannel * facf0;
+			achannel = rt1[3];
+			rt1[3] = (unsigned int) achannel * facf0;
 			blend_function(rt, rt1, rt2);
-			rt2[3] = achannel;
-			rt[3] = rt2[3];
+			rt1[3] = achannel;
+			rt[3] = rt1[3];
 			rt1 += 4;
 			rt2 += 4;
 			rt += 4;
@@ -1332,11 +1332,11 @@ BLI_INLINE void apply_blend_function_byte(
 		}
 		y--;
 		for (x = xo; x > 0; x--) {
-			achannel = rt2[3];
-			rt2[3] = (unsigned int) achannel * facf1;
+			achannel = rt1[3];
+			rt1[3] = (unsigned int) achannel * facf1;
 			blend_function(rt, rt1, rt2);
-			rt2[3] = achannel;
-			rt[3] = rt2[3];
+			rt1[3] = achannel;
+			rt[3] = rt1[3];
 			rt1 += 4;
 			rt2 += 4;
 			rt += 4;
@@ -1357,11 +1357,11 @@ BLI_INLINE void apply_blend_function_float(
 	rt = out;
 	while (y--) {
 		for (x = xo; x > 0; x--) {
-			achannel = rt2[3];
-			rt2[3] = achannel * facf0;
+			achannel = rt1[3];
+			rt1[3] = achannel * facf0;
 			blend_function(rt, rt1, rt2);
-			rt2[3] = achannel;
-			rt[3] = rt2[3];
+			rt1[3] = achannel;
+			rt[3] = rt1[3];
 			rt1 += 4;
 			rt2 += 4;
 			rt += 4;
@@ -1371,11 +1371,11 @@ BLI_INLINE void apply_blend_function_float(
 		}
 		y--;
 		for (x = xo; x > 0; x--) {
-			achannel = rt2[3];
-			rt2[3] = achannel * facf1;
+			achannel = rt1[3];
+			rt1[3] = achannel * facf1;
 			blend_function(rt, rt1, rt2);
-			rt2[3] = achannel;
-			rt[3] = rt2[3];
+			rt1[3] = achannel;
+			rt[3] = rt1[3];
 			rt1 += 4;
 			rt2 += 4;
 			rt += 4;



More information about the Bf-blender-cvs mailing list