Combine multiple video files into one.

This commit is contained in:
Markus Birth 2017-12-05 02:28:51 +01:00
parent 7df722df66
commit 617628d644
Signed by: mbirth
GPG Key ID: A9928D7A098C3A9A

14
ffcat.sh Executable file
View File

@ -0,0 +1,14 @@
#!/bin/sh
TMPFILE=`mktemp`
BASENAME=`basename "$1"`
while [ $# -gt 0 ]; do
THISFILE=`realpath "$1"`
echo "file '${THISFILE}'">>$TMPFILE
# echo "file '${1}'">>$TMPFILE
shift
done
EXT="${BASENAME##*.}"
NAMENOEXT="${BASENAME%.*}"
echo "Output ext: $EXT"
ffmpeg -f concat -safe 0 -i "$TMPFILE" -codec copy "${NAMENOEXT}_combined.${EXT}"
rm "$TMPFILE"