Message ID | 20221018123701.25002-14-anton@khirnov.net |
---|---|
State | Accepted |
Commit | 3c7dd5ed37da6d2de06c4850de5a319ca9cdd47f |
Headers | show |
Series | [FFmpeg-devel,01/20] fftools/ffmpeg_opt: move opening input files to ffmpeg_demux.c | expand |
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 |
On Tue, Oct 18, 2022 at 02:36:55PM +0200, Anton Khirnov wrote: > It does the same thing as the block right below it. > --- > fftools/ffmpeg_mux_init.c | 10 ---------- > 1 file changed, 10 deletions(-) This seems to make a difference for ffmpeg -i meta.flac -map_metadata:s -1 -vcodec mpeg4 -t 0.1 -y /tmp/tmp3x.mkv The metadata in meta.flac is a bit odd though Input #0, flac, from '/home/michael/videos/meta.flac': Metadata: al : Hyper fast Audio and Video encoder : usage: ffmpeg [options] [[infile options] -i infile]... {[outfile options] outfile}... : : Main options: .... : -param1 <double> E.V.. scaler param 1 x : öäü?ß^x²€ encoder : Lavf54.0.100 Duration: 00:03:07.66, start: 0.000000, bitrate: 706 kb/s Stream #0:0: Audio: flac, 48000 Hz, stereo, s16 At least one output file must be specified [...]
Quoting Michael Niedermayer (2022-10-18 23:51:22) > On Tue, Oct 18, 2022 at 02:36:55PM +0200, Anton Khirnov wrote: > > It does the same thing as the block right below it. > > --- > > fftools/ffmpeg_mux_init.c | 10 ---------- > > 1 file changed, 10 deletions(-) > > This seems to make a difference for > ffmpeg -i meta.flac -map_metadata:s -1 -vcodec mpeg4 -t 0.1 -y /tmp/tmp3x.mkv > > The metadata in meta.flac is a bit odd though > > Input #0, flac, from '/home/michael/videos/meta.flac': > Metadata: > al : Hyper fast Audio and Video encoder > : usage: ffmpeg [options] [[infile options] -i infile]... {[outfile options] outfile}... > : > : Main options: > .... > : -param1 <double> E.V.. scaler param 1 > x : öäü?ß^x²€ Is this before or after? If I'm reading the code correctly, no metadata should be copied after my patch, which IMO is more consistent with the docs.
Will push the rest of this set soonish if noone has further comments.
On Tue, Nov 08, 2022 at 01:46:57PM +0100, Anton Khirnov wrote: > Quoting Michael Niedermayer (2022-10-18 23:51:22) > > On Tue, Oct 18, 2022 at 02:36:55PM +0200, Anton Khirnov wrote: > > > It does the same thing as the block right below it. > > > --- > > > fftools/ffmpeg_mux_init.c | 10 ---------- > > > 1 file changed, 10 deletions(-) > > > > This seems to make a difference for > > ffmpeg -i meta.flac -map_metadata:s -1 -vcodec mpeg4 -t 0.1 -y /tmp/tmp3x.mkv > > > > The metadata in meta.flac is a bit odd though > > > > Input #0, flac, from '/home/michael/videos/meta.flac': > > Metadata: > > al : Hyper fast Audio and Video encoder > > : usage: ffmpeg [options] [[infile options] -i infile]... {[outfile options] outfile}... > > : > > : Main options: > > .... > > : -param1 <double> E.V.. scaler param 1 > > x : öäü?ß^x²€ > > Is this before or after? > > If I'm reading the code correctly, no metadata should be copied after my > patch, which IMO is more consistent with the docs. sorry for the delay, the metadata disappears as you describe after the patch thx [...]
diff --git a/fftools/ffmpeg_mux_init.c b/fftools/ffmpeg_mux_init.c index a471bbf469..9e0164ba19 100644 --- a/fftools/ffmpeg_mux_init.c +++ b/fftools/ffmpeg_mux_init.c @@ -1455,16 +1455,6 @@ static int copy_metadata(const char *outspec, const char *inspec, AVFormatContex parse_meta_type(inspec, &type_in, &idx_in, &istream_spec); parse_meta_type(outspec, &type_out, &idx_out, &ostream_spec); - if (!ic) { - if (type_out == 'g' || !*outspec) - o->metadata_global_manual = 1; - if (type_out == 's' || !*outspec) - o->metadata_streams_manual = 1; - if (type_out == 'c' || !*outspec) - o->metadata_chapters_manual = 1; - return 0; - } - if (type_in == 'g' || type_out == 'g') o->metadata_global_manual = 1; if (type_in == 's' || type_out == 's')