[FFmpeg-cvslog] lavfi/drawbox: remove some unnecessary parentheses

Stefano Sabatini git at videolan.org
Wed Oct 31 12:21:24 CET 2012


ffmpeg | branch: master | Stefano Sabatini <stefasab at gmail.com> | Wed Oct 31 12:20:50 2012 +0100| [755038d07d4ca8a3aa20a3cc6c4d86a8a0c1177d] | committer: Stefano Sabatini

lavfi/drawbox: remove some unnecessary parentheses

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

 libavfilter/vf_drawbox.c |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/libavfilter/vf_drawbox.c b/libavfilter/vf_drawbox.c
index 79d68f4..a1ae19b 100644
--- a/libavfilter/vf_drawbox.c
+++ b/libavfilter/vf_drawbox.c
@@ -131,7 +131,7 @@ static int draw_slice(AVFilterLink *inlink, int y0, int h, int slice_dir)
     unsigned char *row[4];
     AVFilterBufferRef *picref = inlink->cur_buf;
 
-    for (y = FFMAX(yb, y0); y < (y0 + h) && y < (yb + drawbox->h); y++) {
+    for (y = FFMAX(yb, y0); y < y0 + h && y < yb + drawbox->h; y++) {
         row[0] = picref->data[0] + y * picref->linesize[0];
 
         for (plane = 1; plane < 3; plane++)
@@ -139,12 +139,12 @@ static int draw_slice(AVFilterLink *inlink, int y0, int h, int slice_dir)
                 picref->linesize[plane] * (y >> drawbox->vsub);
 
         if (drawbox->invert_color) {
-            for (x = FFMAX(xb, 0); x < (xb + drawbox->w) && x < picref->video->w; x++)
+            for (x = FFMAX(xb, 0); x < xb + drawbox->w && x < picref->video->w; x++)
                 if ((y - yb < 3) || (yb + drawbox->h - y < 4) ||
                     (x - xb < 3) || (xb + drawbox->w - x < 4))
                     row[0][x] = 0xff - row[0][x];
         } else {
-            for (x = FFMAX(xb, 0); x < (xb + drawbox->w) && x < picref->video->w; x++) {
+            for (x = FFMAX(xb, 0); x < xb + drawbox->w && x < picref->video->w; x++) {
                 double alpha = (double)drawbox->yuv_color[A] / 255;
 
                 if ((y - yb < 3) || (yb + drawbox->h - y < 4) ||



More information about the ffmpeg-cvslog mailing list