Sightseer
Posts: 6
Re: What program to trim clips keeping metadata

I finally got around to posting an update on how to copy metadata.  The process is below...

 

Kajuna's GoPro utilities has recently been update with a new batch script "Metadata Copier.bat". This has the capability to copy the metadata from a source video file to a post processed video file that lacks the metadata of the original.

 

I post process and color corect my GoPro files using DaVinci Resolve. The problem I had is when exporting video from DaVinci Resolve, the metadata and timestamp information was being stripped out, so all of my GPS data was lost. I developed this script to copy all of that useful metadata from the original GoPro files to the post-processed files. This script just copies the data, so the source file length and framerate should be the same as the original, or you might have issues.

 

To run the script, you'll want to have your input files (original GoPro files with metadata) and corrected files (with the edits, color corrections, etc.) organized correctly. Drag an original GoPro source file onto the script and it will process all of the source .MP4 files in that directory that correspond to a corrected file in the "EditedVideoPath".

 

You may edit the top portion of the batch file to change the default settings, if necessary. The script will look at the source GoPro .MP4 files and use the settings chosen to search for a corresponding edited file to process. You may change which folder edited files are in, and anything you have prepended or postpended to the file name (the base filename needs to remain intact). You may also edit the batch file to change which folder the script will output files to and any prepended or postpended text to the filename.

 

Tip: Use Bulk Rename Utility to easily manage file naming:

https://www.bulkrenameutility.co.uk/Download.php

 

Example (using defaults):
Original GoPro files (source files for metadata): "C:\Source Files\GoPro Video 1.mp4"
Edited (color corrected files, source for video/audio): "C:\Source Files\Edited Video\GoPro Video 1.mp4"
The metadata corrected files will export to: "C:\Source Files\Metadata Fix\GoPro Video 1_MDF.mp4"

The options you can edit in the batch file:

 

:: This is the name of the nested directory that contains the edited/color corrected video files.
set EditedVideoPath=Edited Video

:: Edit this to tell the script anything that has been prepended to the filename of the edited/color corrected video files.
set EditedPrepend=

:: Edit this to tell the script anything that has been postpended to the filename of the edited/color corrected video files.
set EditedPostpend=

:: Directory to export the processed files to (nested under source file directory).
set ExportVideoPath=Metadata Fix

:: Optional text to postpend to the exported video files (with the correct video/metadata)
set MetadataFixedPostPend=_MDF

 

FYI, I mostly used this process to color correct my video files. Credit to "The Loam Ranger" for the awesome process:
Part 1: https://www.youtube.com/watch?v=2YEePcJZcFI
Part 2: https://www.youtube.com/watch?v=NXnBCkF9jUQ&t=633s

It's the ultimate action cam / GoPro tutorial. HERES PART 2: https://youtu.be/NXnBCkF9jUQ No BS, all solid info. Professional videographer and photographer Ryan Kelly from The Loam Ranger walks through the essential steps to getting pro quality action camera footage. Let's do this. Yes I bought a
Part 2/2 from my GoPro and action cam series is here! In this tutorial video, I cover exactly how I take my raw, unprocessed GoPro footage and turn it into sharp, vibrant video, ready to share with friends around the world. For me, it's all about creating action cam video that is as close to the ...