[FFmpeg-user] filter ffmetadata does not output all metadata and is missing in documentation

Ulf Zibis Ulf.Zibis at gmx.de
Thu Mar 5 02:03:22 EET 2020

Am 04.03.20 um 12:10 schrieb Moritz Barsnick:
> Hallo Ulf,
> On Wed, Mar 04, 2020 at 01:51:37 +0100, Ulf Zibis wrote:
>> Even with normal transcoding "creation_time" is listed in the OUTPUT
>> metadata, but in the resulting output file it is missing.
> Interesting and slightly annoying fact: All metadata that is passed to
> encoder and muxer is listed. Yet it is up to encoder and muxer, which
> of these are actually used. (E.g. as far as I understand, MOV/MP4 has a
> limited set of what can be used.)
Unfortunately, the "officials" have a different oppinion:

>>>>       ffmpeg: dont copy creation_time as the destination file is not created at that time
>> Linux command "mediainfo" distinguishes between "Encoded date" and
>> "Tagged date", don't know which is meant to be "creation_time".
>> In jpeg EXIF we find "DateTimeOriginal" and "DateTimeDigitized".
> Perhaps this could be documented somewhere, but I don't personally
> care, in this case.
I have added a comment here: https://trac.ffmpeg.org/ticket/1439#comment:2

>>> Trac ticket cause: http://trac.ffmpeg.org/ticket/1439
>> That may make sense for normal transcoding, but not for:
>> ffmpeg -i INPUT.mp4 -f ffmetadata INPUT.meta
> In all honesty - also for some other "info" filters and muxers -
> information *dumping* should happen at input level, not at output.
> That's why ffprobe was mentioned.
> On the other hand, in terms of passing on to output, that's of course a
> different matter. At least this muxer helped you to notice that this
> specific metadata does *not* arrive at the output.
>> But how to transfer it to the output video?
> Since it's explicitly filtered: Have you tried adding it explicitly,
> from the command line?
> $ ffmpeg [...] -metadata creation_time=2020-03-04T10:38:45.000000Z [...]
No, but I guess it will work. Anyway I was looking for a "automatic"

> Actually, a quick Google search(!) shows me that there's an option for
> passing it from the input:
> $ ffmpeg [...] -map_metadata 0:g [...]
> and it seems to work for me.

Which is the same than "-map_metadata 0".

But here I was talking about the example from
https://ffmpeg.org/ffmpeg-formats.html#Metadata-1 :
ffmpeg -i INPUT -f ffmetadata FFMETADATAFILE
ffmpeg -i INPUT -i FFMETADATAFILE -map_metadata 1 -codec copy OUTPUT
... which doesn't work for complete metadata.


More information about the ffmpeg-user mailing list