[FFmpeg-devel] [PATCH 1/2] lavfi/drawutils: fix blending computation in blend_line function
Matthieu Bouron
matthieu.bouron at gmail.com
Fri Jan 4 22:08:11 CET 2013
If width is not alligned with hsub, background component should only be
multiplied once by sub alpha component.
---
libavfilter/drawutils.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/libavfilter/drawutils.c b/libavfilter/drawutils.c
index aefd09d..aebc000 100644
--- a/libavfilter/drawutils.c
+++ b/libavfilter/drawutils.c
@@ -313,7 +313,6 @@ static void blend_line(uint8_t *dst, unsigned src, unsigned alpha,
unsigned tau = 0x1010101 - alpha;
int x;
- src *= alpha;
if (left) {
unsigned suba = (left * alpha) >> hsub;
*dst = (*dst * (0x1010101 - suba) + src * suba) >> 24;
--
1.8.1
More information about the ffmpeg-devel
mailing list