Categories: 🠪 General
Email 🠪 Servers
🠪 Testing
🠪 Tips
Hardware 🠪 3D Printing
🠪 Apple
🠪 Batteries
🠪 Drives
🠪 Edgerouter
🠪 Electronics
🠪 Laptop
🠪 Modems
🠪 Phone
🠪 Printers
🠪 Raspberry Pi
🠪 Tablets
🠪 Testing
🠪 Virtualization
hidden 🠪 General
Links 🠪 Interesting
🠪 Media
Network 🠪 Data
🠪 Testing
🠪 VPN
Scripts 🠪 Batch
🠪 Linux
🠪 Powershell
Servers 🠪 Databases
🠪 Misc
🠪 Website
Software 🠪 Other
Utilities 🠪 Backup
🠪 Fix Issues
🠪 Recovery
Video 🠪 Editing
Websites 🠪 HTML
🠪 Testing
Windows 🠪 Adjustments
🠪 Issues
🠪 Remote Desktop
🠪 Security
🠪 Slow
🠪 Software
🠪 Startup
Submit Entry
| Airin's Notes
Category: Scripts 🠪 Batch
Handbrake Batch File to convert passed folders/files | November 27, 2023 |
@echo off
REM Loop through each argument (dragged item)
:loop
if "%~1"=="" goto end
REM Create a directory for the current item
mkdir "D:\video\temp\%~n1"
FOR /F "tokens=*" %%G IN ('DIR "%~1" /B /S /A:-d') do (
FOR /F "tokens=*" %%H IN ('DIR "%%G" /B /A:-d') do (
"C:\Program Files\Handbrake\HandBrakeCLI" -i "%%G" --optimize -o "D:\video\temp\%~n1\%%~nH.mp4" -e nvenc_h265 -q 26 --cfr --aencoder av_aac --verbose=1
)
)
REM Shift arguments to process the next item
shift
goto loop
:end
pause
Thanks to Dave for this script: https://www.youtube.com/watch?v=dJJpCxoNgoM
Keywords: Handbrake, batch, convert, mpeg |
|