Advertisement
mimoprohodil

EasyPrev

Jul 13th, 2015
273
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Batch 0.62 KB | None | 0 0
  1. @echo off
  2. if "%~1"=="" goto error
  3. if "%~2"=="" goto error
  4. if "%~3"=="" goto error
  5. if exist EasyPrev.txt del EasyPrev.txt
  6. ffmpeg -hide_banner -ss %3 -i "%~1" -vframes 1 -c copy -an -y TEMP_EasyPrev_preview.webm
  7. copy /Y %1 TEMP_EasyPrev_source.webm
  8. echo file 'TEMP_EasyPrev_preview.webm'>nul>>EasyPrev.txt
  9. echo file 'TEMP_EasyPrev_source.webm'>>EasyPrev.txt
  10. ffmpeg -hide_banner -itsoffset 0.04 -i "%~1" -f concat -i EasyPrev.txt -map 1:v -map 0:a -c copy -y "%~2.webm"
  11. del TEMP_EasyPrev_preview.webm
  12. del TEMP_EasyPrev_source.webm
  13. del EasyPrev.txt
  14. goto exit
  15. :error
  16. echo ##### Error! #####
  17. :exit
  18. echo ##### Script End #####
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement