Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @ECHO OFF
- SETLOCAL
- COLOR 0A
- TITLE RECURSIVELY CONVERT FLAC FILES TO MP3
- :-----------------------------------------------------------------------------------------------------------------
- REM Output file specs: mp3 @ 320kbps
- REM By: SlyFox1186
- REM Pastebin: https://pastebin.com/u/slyfox1186
- REM IMPORTANT 1.. !Always! test run this script
- REM before running it on your irreplaceable files!
- REM IMPORTANT 2.. Make sure to point the 'FF' variable
- REM below to your ffmpeg.exe's full path.
- REM The script will also transfer any embedded images
- REM found inside each FLAC file inside the output file.
- :-----------------------------------------------------------------------------------------------------------------
- PUSHD "%~dp0"
- IF NOT "%1"=="MAX" START /MAX CMD /D /C %0 MAX & GOTO :EOF
- :-----------------------------------------------------------------------------------------------------------------
- SET FF="PATH\TO\ffmpeg.exe"
- :-----------------------------------------------------------------------------------------------------------------
- :RUN_FFMPEG
- :-----------------------------------------------------------------------------------------------------------------
- SETLOCAL ENABLEEXTENSIONS ENABLEDELAYEDEXPANSION
- SET CNT=
- FOR /R %%G IN (*.flac) DO (
- SET /A CNT+=1
- SET "ADIR=%AppData%\%%~nG.jpg"
- %FF% -y -nostats -hide_banner -vsync 2 -color_range 2 -i "%%~fG" "!ADIR!"
- ECHO= & ECHO=
- ECHO [ #!CNT! ] %%~nxG
- ECHO= & ECHO=
- %FF% -y -nostats -hide_banner -vsync 2 -color_range 2 -i "!ADIR!" -y ^
- -i "%%~fG" -ab 320k -ac 2 -map_metadata 0 -id3v2_version 3 "%%~dpnG.mp3"
- DEL /F /Q "!ADIR!" >NUL
- ECHO= & ECHO=
- )
- :-----------------------------------------------------------------------------------------------------------------
- ENDLOCAL
- COLOR 0E
- ECHO=
- ECHO [92mFFMPEG COMPLETED![0m
- ECHO=
- PAUSE
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement