]> git.sesse.net Git - ffmpeg/blobdiff - libavfilter/vf_cropdetect.c
lavfi: move color filter to testsrc, factorize
[ffmpeg] / libavfilter / vf_cropdetect.c
index 8ffbe7094994a0ea7c8757e8e60e812fdafbc0bc..b245d6e12be2eb132ec0dfef03e529ec8a6e235a 100644 (file)
@@ -114,7 +114,7 @@ static int config_input(AVFilterLink *inlink)
     return 0;
 }
 
-static void end_frame(AVFilterLink *inlink)
+static int end_frame(AVFilterLink *inlink)
 {
     AVFilterContext *ctx = inlink->dst;
     CropDetectContext *cd = ctx->priv;
@@ -191,7 +191,7 @@ static void end_frame(AVFilterLink *inlink)
                w, h, x, y);
     }
 
-    ff_end_frame(inlink->dst->outputs[0]);
+    return ff_end_frame(inlink->dst->outputs[0]);
 }
 
 AVFilter avfilter_vf_cropdetect = {
@@ -203,15 +203,15 @@ AVFilter avfilter_vf_cropdetect = {
 
     .query_formats = query_formats,
 
-    .inputs    = (const AVFilterPad[]) {{ .name       = "default",
-                                    .type             = AVMEDIA_TYPE_VIDEO,
-                                    .config_props     = config_input,
-                                    .get_video_buffer = ff_null_get_video_buffer,
-                                    .start_frame      = ff_null_start_frame,
-                                    .end_frame        = end_frame, },
-                                  { .name = NULL}},
-
-    .outputs   = (const AVFilterPad[]) {{ .name       = "default",
-                                    .type             = AVMEDIA_TYPE_VIDEO },
-                                  { .name = NULL}},
+    .inputs    = (const AVFilterPad[]) {{ .name = "default",
+                                          .type             = AVMEDIA_TYPE_VIDEO,
+                                          .config_props     = config_input,
+                                          .get_video_buffer = ff_null_get_video_buffer,
+                                          .start_frame      = ff_null_start_frame,
+                                          .end_frame        = end_frame, },
+                                        { .name = NULL}},
+
+    .outputs   = (const AVFilterPad[]) {{ .name             = "default",
+                                          .type             = AVMEDIA_TYPE_VIDEO },
+                                        { .name = NULL}},
 };