[FFmpeg-cvslog] avfilter/vf_removelogo: fix offset for accessing pixels above and below

Michael Niedermayer git at videolan.org
Sat Oct 12 12:14:03 CEST 2013


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sat Oct 12 11:35:54 2013 +0200| [8c582d1b221346eb120fff0cf2214d4218ba4022] | committer: Michael Niedermayer

avfilter/vf_removelogo: fix offset for accessing pixels above and below

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=8c582d1b221346eb120fff0cf2214d4218ba4022
---

 libavfilter/vf_removelogo.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavfilter/vf_removelogo.c b/libavfilter/vf_removelogo.c
index ea04ce0..d132e30 100644
--- a/libavfilter/vf_removelogo.c
+++ b/libavfilter/vf_removelogo.c
@@ -174,8 +174,8 @@ static void convert_mask_to_strength_mask(uint8_t *data, int linesize,
                 if ( *current_pixel      >= current_pass &&
                     *(current_pixel + 1) >= current_pass &&
                     *(current_pixel - 1) >= current_pass &&
-                    *(current_pixel + w) >= current_pass &&
-                    *(current_pixel - w) >= current_pass) {
+                    *(current_pixel + linesize) >= current_pass &&
+                    *(current_pixel - linesize) >= current_pass) {
                     /* Increment the value since it still has not been
                      * eroded, as evidenced by the if statement that
                      * just evaluated to true. */



More information about the ffmpeg-cvslog mailing list