summaryrefslogtreecommitdiff
path: root/fftools/ffmpeg_opt.c
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2023-02-06 13:14:53 +0100
committerAnton Khirnov <anton@khirnov.net>2023-02-09 15:24:15 +0100
commit42a0dd6e7e3bc343d65a5499bd1373ad15160ab7 (patch)
tree8ee8b198e6cce3828dad6fe5334fd8bc22e72575 /fftools/ffmpeg_opt.c
parent6d4f3ae116eaa6552434c9c73eb8d84f7be07c91 (diff)
fftools/ffmpeg: add an option for writing pre-muxing stats
Analogous to -enc_stats*, but happens right before muxing. Useful because bitstream filters and the sync queue can modify packets after encoding and before muxing. Also has access to the muxing timebase.
Diffstat (limited to 'fftools/ffmpeg_opt.c')
-rw-r--r--fftools/ffmpeg_opt.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/fftools/ffmpeg_opt.c b/fftools/ffmpeg_opt.c
index 799dcf071e..ed7ee6ab7d 100644
--- a/fftools/ffmpeg_opt.c
+++ b/fftools/ffmpeg_opt.c
@@ -1548,10 +1548,14 @@ const OptionDef options[] = {
"write encoding stats before encoding" },
{ "enc_stats_post", HAS_ARG | OPT_SPEC | OPT_EXPERT | OPT_OUTPUT | OPT_STRING, { .off = OFFSET(enc_stats_post) },
"write encoding stats after encoding" },
+ { "stats_mux_pre", HAS_ARG | OPT_SPEC | OPT_EXPERT | OPT_OUTPUT | OPT_STRING, { .off = OFFSET(mux_stats) },
+ "write packets stats before muxing" },
{ "enc_stats_pre_fmt", HAS_ARG | OPT_SPEC | OPT_EXPERT | OPT_OUTPUT | OPT_STRING, { .off = OFFSET(enc_stats_pre_fmt) },
"format of the stats written with -enc_stats_pre" },
{ "enc_stats_post_fmt", HAS_ARG | OPT_SPEC | OPT_EXPERT | OPT_OUTPUT | OPT_STRING, { .off = OFFSET(enc_stats_post_fmt) },
"format of the stats written with -enc_stats_post" },
+ { "stats_mux_pre_fmt", HAS_ARG | OPT_SPEC | OPT_EXPERT | OPT_OUTPUT | OPT_STRING, { .off = OFFSET(mux_stats_fmt) },
+ "format of the stats written with -stats_mux_pre" },
/* video options */
{ "vframes", OPT_VIDEO | HAS_ARG | OPT_PERFILE | OPT_OUTPUT, { .func_arg = opt_video_frames },