2017-06-15 717 views
-2

我需要將採樣率提高10%。輸入文件的採樣率未知。FFmpeg更改音頻採樣率

我發現了這個。 1個文件的示例:

ffmpeg -i xxx.mp3 -filter:a "asetrate=$(ffprobe -v error -show_entries stream=sample_rate -of default=noprint_wrappers=1:nokey=1 xxx.mp3)*1.1" -y xxx1.mp3 

但是不工作並創建0kb文件。

LOG:

[asetrate @ 00000000024242e0] ​​[評估和演示@ 00000000005fde80]未定義 恆定或丟失 '(' 在 'ffprobe-VERROR-show_entriesstream = SAMPLE_RATE-ofdefault = noprint_wrappers = 1' [asetrate @ 00000000024242e0]無法解析選項值 「$(ffprobe -v錯誤-show_entries流= SAMPLE_RATE -of默認= noprint_wrappers = 1」[Parsed_asetrate_0 @ 0000000000e6cb20] 選項 'NOKEY' 未找到[AVFilterGraph @ 0000000002419ca0]錯誤 初始化濾波器'arsetrate'with args'$(ffprobe -v error -show_entries stream = sample_rate -of default = noprint_wrappers = 1:nokey = 1 xxx.mp3)* 1.1'錯誤重新初始化 過濾器!無法將幀注入過濾網:找不到選項 處理流#0的解碼數據時出錯:0轉換 失敗!

+1

看起來像你的子命令不工作。也許是 – Brad

+0

。但是這個答案根本沒有幫助。 –

+1

你的問題根本沒有幫助。你沒有試圖找出問題。你在使用Bash嗎? Windows CMD?電源外殼?什麼? – Brad

回答

0

您需要在ffprobe命令中對每個「:」進行轉義。