Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
lemisky authored Oct 25, 2024
1 parent 1855209 commit 07acbba
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,13 +93,13 @@ data**](https://en.wikipedia.org/wiki/Pulse-code_modulation) 完成的
2. PCM ➜ 音频文件
```bat
ffmpeg -y -f s16le -i <PCM输入文件> -ar <采样率> -ac <声道数> <音频输出文件>
ffmpeg -y -f s16le -ar <采样率> ~-ac <声道数>~ -i <PCM输入文件> <音频输出文件>
```
1. `-f`: 这里必须为 `s16le`, 同样也是由 **SILK** 决定的
2. `-ar`: 同上
3. `-ac`: 含义同上,值随意
4. `<音频输出文件>`: 扩展名要准确,没有指定格式时,**ffmpeg** 会根据给定的输出文件扩展名来判断需要输出的格式
5. example3: `ffmpeg -y -f s16le -i test.pcm test.mp3`
5. example3: `ffmpeg -y -f s16le -ar 16000 -i test.pcm test.mp3`
> ffmpeg 也可以使用 python ffmpeg binding 替换,推荐 [PyAV](https://github.com/PyAV-Org/PyAV) 大家自行研究,这里不再啰嗦。
Expand Down

0 comments on commit 07acbba

Please sign in to comment.