diff mbox series

[FFmpeg-devel,02/11] avfilter/f_drawgraph: Deduplicate outputs

Message ID GV1SPRMB0033542F721360F0C01664AD8FA7A@GV1SPRMB0033.EURP250.PROD.OUTLOOK.COM
State Accepted
Commit a02670ded71ef718799799d9f92b65c02852bd40
Headers show
Series [FFmpeg-devel,01/11] avcodec/aactab: Deduplicate swb_offset_960 tabs | 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

Andreas Rheinhardt Nov. 1, 2023, 8:35 a.m. UTC
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 libavfilter/f_drawgraph.c | 25 ++++++++-----------------
 1 file changed, 8 insertions(+), 17 deletions(-)
diff mbox series

Patch

diff --git a/libavfilter/f_drawgraph.c b/libavfilter/f_drawgraph.c
index d29a7fb60a..d53598ee15 100644
--- a/libavfilter/f_drawgraph.c
+++ b/libavfilter/f_drawgraph.c
@@ -454,22 +454,22 @@  static av_cold void uninit(AVFilterContext *ctx)
     av_freep(&s->values[3]);
 }
 
-#if CONFIG_DRAWGRAPH_FILTER
-
-static const AVFilterPad drawgraph_inputs[] = {
+static const AVFilterPad drawgraph_outputs[] = {
     {
         .name         = "default",
         .type         = AVMEDIA_TYPE_VIDEO,
-        .filter_frame = filter_frame,
+        .config_props = config_output,
+        .request_frame = request_frame,
     },
 };
 
-static const AVFilterPad drawgraph_outputs[] = {
+#if CONFIG_DRAWGRAPH_FILTER
+
+static const AVFilterPad drawgraph_inputs[] = {
     {
         .name         = "default",
         .type         = AVMEDIA_TYPE_VIDEO,
-        .config_props = config_output,
-        .request_frame = request_frame,
+        .filter_frame = filter_frame,
     },
 };
 
@@ -497,15 +497,6 @@  static const AVFilterPad adrawgraph_inputs[] = {
     },
 };
 
-static const AVFilterPad adrawgraph_outputs[] = {
-    {
-        .name         = "default",
-        .type         = AVMEDIA_TYPE_VIDEO,
-        .config_props = config_output,
-        .request_frame = request_frame,
-    },
-};
-
 const AVFilter ff_avf_adrawgraph = {
     .name          = "adrawgraph",
     .description   = NULL_IF_CONFIG_SMALL("Draw a graph using input audio metadata."),
@@ -514,7 +505,7 @@  const AVFilter ff_avf_adrawgraph = {
     .init          = init,
     .uninit        = uninit,
     FILTER_INPUTS(adrawgraph_inputs),
-    FILTER_OUTPUTS(adrawgraph_outputs),
+    FILTER_OUTPUTS(drawgraph_outputs),
     FILTER_QUERY_FUNC(query_formats),
 };
 #endif // CONFIG_ADRAWGRAPH_FILTER