Last active
December 31, 2019 12:22
-
-
Save goooseman/3b7e71f85d3c34bb8f18d13478c4b5ad to your computer and use it in GitHub Desktop.
Convert any .mp4 video to be used in DJI Quik software
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Based on https://riviera.org.uk/2018/10/23/importing-non-gopro-videos-into-gopro-quik/ | |
if [ -d "$1" ] | |
then | |
mkdir "$1/GoPro Quik" | |
for filename in "$1"/*.mp4; do | |
filename_base=$(basename "$filename") | |
ffmpeg -i "$filename" \ | |
-map_metadata \ | |
-1 \ | |
-codec copy \ | |
-metadata:s handler="GoPro AVC encoder" \ | |
-metadata:s handler_name=" GoPro AVC" \ | |
"$1/GoPro Quik/$filename_base" | |
done | |
else | |
echo "Usage: $0 directory" | |
echo "directory should contain .mp4 files" | |
echo "This script convert any .mp4 video to be used in DJI Quik software" | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment