Here is my current script: @echo off setlocal enabledelayedexpansion set…
- User
Here is my current script:
@echo off setlocal enabledelayedexpansion
set "input=Cats_and_Dogs_t00.flac" set "bitrates=640k"
echo Converting FLAC to AC3... for %%b in (%bitrates%) do ( set "output=Cats_and_Dogs_t00_%%b.ac3" ffmpeg -i "%input%" -c:a ac3 -b:a %%b -dialnorm -27 ^ -center_mixlev 0.707 -surround_mixlev 0.707 ^ -ltrt_cmixlev 0.707 -ltrt_surmixlev 0.707 ^ -loro_cmixlev 0.707 -loro_surmixlev 0.595 ^ "!output!" echo Created: "!output!" )
echo All AC3 conversions complete.
echo Generating spectrogram... ffmpeg -i "!output!" ^ -filter_complex "showspectrumpic=s=1920x1080" ^ -update 1 -frames:v 1 "!output:.ac3=_spectrogram.png!" echo Created spectrogram: "!output:.ac3=_spectrogram.png!"
echo All spectrograms generated. pause
Is there any way for me to have the same filename in input as in output (just without .flac in output), so that I don't have to change filename twice in file when I want to convert and create spectrogram?
- Assistant