2024-08-04, 06:26 PM
(This post was last modified: 2024-08-04, 06:45 PM by Ted Hinklater. Edited 1 time in total.)
I used ffmpeg, first to find all the theme.mp3 files, lower their volumes to 10%, and save that as theme_reduced.mp3, after that, a script to delete all the original theme.mp3 files and rename theme_reduced.mp3 files to just theme.mp3
I did it that long way because I didn't want to just screw it up, you can probably modify the code to make it simpler
Step 1: Edit your shows folder path and change ffmpeg_path to wherever you saved ffmpeg to. Save this code as a .bat and run
Step 2: Edit your Shows folder path, save as a .bat and run
I did it that long way because I didn't want to just screw it up, you can probably modify the code to make it simpler
Step 1: Edit your shows folder path and change ffmpeg_path to wherever you saved ffmpeg to. Save this code as a .bat and run
Code:
@echo off
setlocal enabledelayedexpansion
set "source_dir=F:\Shows"
set "ffmpeg_path=C:\path\to\your\ffmpeg.exe"
for /r "%source_dir%" %%A in (Theme.mp3) do (
set "output_file=%%~dpnA_reduced.mp3"
"%ffmpeg_path%" -i "%%A" -filter:a "volume=0.1" -vn "!output_file!" -y
echo File !output_file! created with reduced volume.
)
echo All Theme.mp3 files processed.
Step 2: Edit your Shows folder path, save as a .bat and run
Code:
@echo off
setlocal enabledelayedexpansion
set "source_dir=F:\Shows"
for /r "%source_dir%" %%A in (Theme.mp3) do (
echo Deleting "%%A"
del "%%A"
)
for /r "%source_dir%" %%B in (Theme_reduced.mp3) do (
set "file_path=%%B"
set "file_name=%%~nxB"
set "new_name=!file_name:Theme_reduced=Theme!"
set "new_path=!file_path:%source_dir%=!"
echo Renaming "%%B" to "!new_name!"
ren "%%B" "!new_name!"
)
echo Cleanup complete.