Browse Source

fix ffmpeg-merge

master
VirtuBox 6 months ago
parent
commit
f60bd6f7b1
Signed by: virtubox GPG Key ID: 22EB296C97BAD476
1 changed files with 7 additions and 5 deletions
  1. +7
    -5
      mybashrc

+ 7
- 5
mybashrc View File

@ -728,15 +728,17 @@ _YOUTUBE_ENCODE() {
}
_MERGE_VIDEO() {
rm -f mylist
if [ "$#" -eq 0 ]; then
videos=$(echo ./*)
for i in "$PWD"/*; do
echo "file '$i'" >>mylist.txt
done
else
videos="$*"
for video in $videos; do
echo "file '$video'" >>mylist.txt
done
fi
for video in $videos; do
rm -f mylist
echo "file '$video'" >> mylist.txt
done
ffmpeg -f concat -safe 0 -i mylist.txt -c copy "output-merged.mp4"
}


Loading…
Cancel
Save