diff options
author | Anton Khirnov <anton@khirnov.net> | 2024-04-01 06:29:16 +0200 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2024-04-09 10:34:18 +0200 |
commit | 9d5bf2d69e6ad85adbf8a673929192e0b07bc080 (patch) | |
tree | ff1797ffa77726a9cc6089e114b9645815c4540a /fftools/ffmpeg_mux_init.c | |
parent | 606c71bb117ab32eb91cfa5b8e14594023fb1175 (diff) | |
download | ffmpeg-9d5bf2d69e6ad85adbf8a673929192e0b07bc080.tar.gz |
fftools/ffmpeg_filter: pass enc_timebase through OutputFilterOptions
Reduces the need to access OutputStream, which will allow decoupling
filtering from encoding in future commits.
Diffstat (limited to 'fftools/ffmpeg_mux_init.c')
-rw-r--r-- | fftools/ffmpeg_mux_init.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/fftools/ffmpeg_mux_init.c b/fftools/ffmpeg_mux_init.c index 8b03d3b108..28090423c6 100644 --- a/fftools/ffmpeg_mux_init.c +++ b/fftools/ffmpeg_mux_init.c @@ -1042,6 +1042,7 @@ static int ost_add(Muxer *mux, const OptionsContext *o, enum AVMediaType type, const AVCodec *enc; AVStream *st; int ret = 0, keep_pix_fmt = 0; + AVRational enc_tb = { 0, 0 }; const char *bsfs = NULL, *time_base = NULL; char *filters = NULL, *next, *codec_tag = NULL; double qscale = -1; @@ -1260,7 +1261,7 @@ static int ost_add(Muxer *mux, const OptionsContext *o, enum AVMediaType type, #endif } - ost->enc_timebase = q; + enc_tb = q; } } else { ret = filter_codec_opts(o->g->codec_opts, AV_CODEC_ID_NONE, oc, st, @@ -1377,6 +1378,7 @@ static int ost_add(Muxer *mux, const OptionsContext *o, enum AVMediaType type, (type == AVMEDIA_TYPE_VIDEO || type == AVMEDIA_TYPE_AUDIO)) { OutputFilterOptions opts = { .enc = enc, + .output_tb = enc_tb, .ts_offset = mux->of.start_time == AV_NOPTS_VALUE ? 0 : mux->of.start_time, .flags = OFILTER_FLAG_DISABLE_CONVERT * !!keep_pix_fmt, |