Skip to content

Instantly share code, notes, and snippets.

@Alexhha
Last active March 26, 2023 17:25
Show Gist options
  • Save Alexhha/9652560ac6b87ebaa8f717f2a30ece2a to your computer and use it in GitHub Desktop.
Save Alexhha/9652560ac6b87ebaa8f717f2a30ece2a to your computer and use it in GitHub Desktop.
ffmpeg mov to avi
#!/bin/bash
cd ~/mov_2_avi/source
for curr_file in $(ls *)
do
echo "$(date)"
echo "${curr_file}"
# ffmpeg -i input.mp4 -c:v libx265 -vtag hvc1 output.avi
ffmpeg -i "~/mov_2_avi/source/${curr_file}" -ac 2 -r 30 -vf scale="1280:-1" -c:v libx264 \
-crf 12 -preset veryslow -tune film "~/mov_2_avi/converted/${curr_file%.mov}.avi"
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment