From 69350ba3631d93c155e13b22fae78cd9dfa28911 Mon Sep 17 00:00:00 2001 From: iamdamosuzuki Date: Tue, 3 Nov 2020 13:02:29 -0800 Subject: [PATCH] created xstack script. now we can do american flags --- bash_scripts/xstack.sh | 174 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 174 insertions(+) create mode 100755 bash_scripts/xstack.sh diff --git a/bash_scripts/xstack.sh b/bash_scripts/xstack.sh new file mode 100755 index 0000000..c057b0c --- /dev/null +++ b/bash_scripts/xstack.sh @@ -0,0 +1,174 @@ +#!/usr/bin/env bash + +# Creates a mosiac of video files using the xstack filter + +_usage(){ +cat <&2 + exit +fi + + # Build filter string + + +while getopts "hps" OPT ; do + case "${OPT}" in + h) _usage ; exit 0 + ;; + p) + ffmpeg -hide_banner ${inputStringSave} -c:v prores -profile:v 3 -filter_complex "${filterString}" -map [out] -f matroska - | ffplay - + printf "\n\n*******START FFPLAY COMMANDS*******\n" >&2 + printf "ffmpeg -hide_banner ${inputStringPlay} -c:v prores -profile:v 3 -filter_complex '${filterString}' -map [out] -f matroska - | ffplay - \n" >&2 + printf "********END FFPLAY COMMANDS********\n\n " >&2 + ;; + s) + ffmpeg -hide_banner ${inputStringSave} -c:v prores -profile:v 3 -filter_complex "${filterString}" -map [out] "${2%.*}_xstack_$outDim.mov" + printf "\n\n*******START FFMPEG COMMANDS*******\n" >&2 + printf "ffmpeg -hide_banner ${inputStringPlay} -c:v prores -profile:v 3 -filter_complex '${filterString}' -map [out] '${2%.*}_xstack_$outDim.mov' \n" >&2 + printf "********END FFMPEG COMMANDS********\n\n " >&2 + ;; + *) echo "bad option -${OPTARG}" ; _usage ; exit 1 ; + esac + done