savsanta

webm_bash_encode.sh

Jan 24th, 2021 (edited)
260
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.64 KB | None | 0 0
  1. #!/bin/sh
  2.  
  3.  
  4. # Convert the files in the list
  5.  
  6. SAVE_FOLDER="$HOME/FINCODED"
  7. file=$1
  8.  
  9.  
  10. echo "Utilizing local file: $file"
  11.  
  12. while IFS= read -r line
  13.  
  14. do
  15. echo "Current File Being Processed $line"
  16. line_item=$(basename $line)
  17. ffmpeg -i $line_item -c:v libvpx-vp9 -pass 1 -speed 4 -tile-columns 6 -frame-parallel 1 -an -c:a libopus -b:a 64k -f webm /dev/null
  18. ffmpeg -i $line_item -c:v libvpx-vp9 -b:v 2500K -crf 31 -threads 8 -pass 2 -speed 1 -tile-columns 6 -frame-parallel 1 -c:a libopus -b:a 64k -auto-alt-ref 1 -lag-in-frames 25 -f webm $line_item.processed.webm
  19. echo "The $line_item has been processed."
  20.  
  21. done < "$file"
Add Comment
Please, Sign In to add comment