diff mbox series

[FFmpeg-devel,20/24] fftools/ffmpeg_filter: make ifilter_has_all_input_formats() static

Message ID 20230528091416.17927-20-anton@khirnov.net
State Accepted
Commit 5924b700752574a3c99c4b407ce4b217c34e9c06
Headers show
Series [FFmpeg-devel,01/24] fftools/ffmpeg_mux_init: merge ost_add_from_filter() to ost_add() | expand

Checks

Context Check Description
yinshiyou/make_loongarch64 success Make finished
yinshiyou/make_fate_loongarch64 success Make fate finished
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished

Commit Message

Anton Khirnov May 28, 2023, 9:14 a.m. UTC
It is no longer used outside ffmpeg_filter.
---
 fftools/ffmpeg.h        |  2 --
 fftools/ffmpeg_filter.c | 24 ++++++++++++------------
 2 files changed, 12 insertions(+), 14 deletions(-)
diff mbox series

Patch

diff --git a/fftools/ffmpeg.h b/fftools/ffmpeg.h
index 75695d3fb5..398bcc58e1 100644
--- a/fftools/ffmpeg.h
+++ b/fftools/ffmpeg.h
@@ -751,8 +751,6 @@  void ifilter_sub2video_heartbeat(InputFilter *ifilter, int64_t pts, AVRational t
  */
 int ifilter_parameters_from_dec(InputFilter *ifilter, const AVCodecContext *dec);
 
-int ifilter_has_all_input_formats(FilterGraph *fg);
-
 void ofilter_bind_ost(OutputFilter *ofilter, OutputStream *ost);
 
 /**
diff --git a/fftools/ffmpeg_filter.c b/fftools/ffmpeg_filter.c
index e0843b0729..9c29850a26 100644
--- a/fftools/ffmpeg_filter.c
+++ b/fftools/ffmpeg_filter.c
@@ -537,6 +537,18 @@  fail:
     return ret;
 }
 
+// Filters can be configured only if the formats of all inputs are known.
+static int ifilter_has_all_input_formats(FilterGraph *fg)
+{
+    int i;
+    for (i = 0; i < fg->nb_inputs; i++) {
+        InputFilterPriv *ifp = ifp_from_ifilter(fg->inputs[i]);
+        if (ifp->format < 0)
+            return 0;
+    }
+    return 1;
+}
+
 static char *describe_filter_link(FilterGraph *fg, AVFilterInOut *inout, int in)
 {
     AVFilterContext *ctx = inout->filter_ctx;
@@ -1660,18 +1672,6 @@  static int ifilter_parameters_from_frame(InputFilter *ifilter, const AVFrame *fr
     return 0;
 }
 
-// Filters can be configured only if the formats of all inputs are known.
-int ifilter_has_all_input_formats(FilterGraph *fg)
-{
-    int i;
-    for (i = 0; i < fg->nb_inputs; i++) {
-        InputFilterPriv *ifp = ifp_from_ifilter(fg->inputs[i]);
-        if (ifp->format < 0)
-            return 0;
-    }
-    return 1;
-}
-
 int filtergraph_is_simple(FilterGraph *fg)
 {
     FilterGraphPriv *fgp = fgp_from_fg(fg);