[FFmpeg-devel] [PATCH] lavfi/crop: remove useless instructions for setting x and y default values

Stefano Sabatini stefasab at gmail.com
Wed Jul 10 17:50:59 CEST 2013


Such values are ignored, since they are set in filter_frame().
---
 libavfilter/vf_crop.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/libavfilter/vf_crop.c b/libavfilter/vf_crop.c
index e112c23..832e6cf 100644
--- a/libavfilter/vf_crop.c
+++ b/libavfilter/vf_crop.c
@@ -216,11 +216,6 @@ static int config_input(AVFilterLink *link)
         return AVERROR(EINVAL);
     }
 
-    /* set default, required in the case the first computed value for x/y is NAN */
-    s->x = (link->w - s->w) / 2;
-    s->y = (link->h - s->h) / 2;
-    s->x &= ~((1 << s->hsub) - 1);
-    s->y &= ~((1 << s->vsub) - 1);
     return 0;
 
 fail_expr:
-- 
1.8.1.2



More information about the ffmpeg-devel mailing list