Multiple Inputs

Questions involving a Windows version of FFmpeg.
Posts: 1
Joined: Fri Apr 26, 2019 7:40 am

Re: Multiple Inputs

Post by Ashii »


I found this tutorial really useful ... ith-ffmpeg

If you need to batch convert multiple files,keeping the original file names this solution is working 100%.
Create a .txt file inside the folder with the files you need to convert
Open it and copy this line:

Code: Select all

for %%a in ("*.caf") do ffmpeg.exe -i "%%a" -y "%%~na.flac"
Change it with the codec and other setting you need like:

Code: Select all

for %%a in ("*.mov") do ffmpeg.exe -i "%%a" -y -vcodec hap -format hap -chunks 16 ""
Save it and rename the extension in .bat
Go to your ffmpeg installation folder and copy the .exe file inside the folder with the .bat.

Run the .bat file.
If you need to convert something again, just copy .bat and ffmpeg.exe in the new folder and run it.
This is how mine looks like:

Code: Select all

Echo "++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++"
Echo "030119_Grace                      .caf to .flac Batch converter"

pause "press any key to convert"

for %%a in ("*.caf") do ffmpeg.exe -i "%%a" -y "%%~na.flac"
CHOICE  /c YN /M "delete original input files?"
If Errorlevel 2 Goto No
If Errorlevel 1 Goto Yes

del /s "*.caf"
Echo "Original files deleted"
pause "press any key to exit"

Echo @off

Post Reply