[FFmpeg-devel] [PATCH 2/3] fftools/ffmpeg_opt: Simplify adding complex filtergraph
Andreas Rheinhardt
andreas.rheinhardt at outlook.com
Wed Feb 23 21:50:55 EET 2022
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>
---
fftools/ffmpeg_opt.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/fftools/ffmpeg_opt.c b/fftools/ffmpeg_opt.c
index c22c6aca06..44ec759e35 100644
--- a/fftools/ffmpeg_opt.c
+++ b/fftools/ffmpeg_opt.c
@@ -3271,9 +3271,8 @@ static int opt_audio_qscale(void *optctx, const char *opt, const char *arg)
static int opt_filter_complex(void *optctx, const char *opt, const char *arg)
{
- FilterGraph *fg;
- ALLOC_ARRAY_ELEM(filtergraphs, nb_filtergraphs);
- fg = filtergraphs[nb_filtergraphs - 1];
+ FilterGraph *fg = ALLOC_ARRAY_ELEM(filtergraphs, nb_filtergraphs);
+
fg->index = nb_filtergraphs - 1;
fg->graph_desc = av_strdup(arg);
if (!fg->graph_desc)
--
2.32.0
More information about the ffmpeg-devel
mailing list