![.mp3 可以批量合并图片和音频,但 .aac 不行](https://linux22.com/image/1627543/.mp3%20%E5%8F%AF%E4%BB%A5%E6%89%B9%E9%87%8F%E5%90%88%E5%B9%B6%E5%9B%BE%E7%89%87%E5%92%8C%E9%9F%B3%E9%A2%91%EF%BC%8C%E4%BD%86%20.aac%20%E4%B8%8D%E8%A1%8C.png)
当音频文件类型为 .mp3 时,此方法有效,但如果音频文件类型为 aac,则无效,我做错了什么?
echo off
for %%a in ("*.aac") do (
ffmpeg -i "%%a" -an -vcodec copy "images\%%~na.jpg"
"C:\ffmpeg\bin\ffmpeg" -loop 1 -i "images\%%~na.jpg" -i "%%a" -c:v libx264 -preset veryslow -tune stillimage -crf 18 -pix_fmt yuv420p -c:a aac -shortest -strict experimental -b:a 192k -shortest "video\%%~na.mp4" )
pause
答案1
在 CMD 中运行它,忘记了 Windows cmd = % 和 batch = %%