copy GPS info and Nikon makernotes from MOV file to MP4 file?

Started by dgonyier, January 18, 2018, 10:56:10 PM

Previous topic - Next topic

dgonyier

I have been playing around with the video capture feature of my Nikon D3400 and unfortunately it likes to package H.264 video and PCM audio in MOV files, so I have to use ffmpeg to losslessly repackage the video and audio streams into a MP4 container.

When it comes to the metadata, there is a lot that exiftool doesn't copy from MOV to MP4, in particular the Nikon makernotes and GPS information. I assume this is because there isn't a mapping for those items in MP4 land (or because the new container output from ffmpeg doesn't have existing compatible0 tags to update with this metadata).

As a backup plan, I would like to copy the Nikon makernotes and GPS information as plain text into a MP4 COMMENT field. Is there a one-line method to do this rather than using an intermediate file and then running exiftool again to import that data as text into a MP4 comment field? I would like to write a wrapper script to batch import these fields from the MOV container to the corresponding MP4 container as I dump videos from my camera.

Phil Harvey

ExifTool can add XMP to MOV/MP4, but that is the only type of metadata it can add to these files.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).