2
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

soxの使い方まとめ

Last updated at Posted at 2020-01-13

音声ファイルの結合

$ sox inputA.wav inputB.wav inputC.wav output.wav

無音区間のカット


# デジタル信号は0%でいい
sox input.wav output.wav silence 1 0.1 0% reverse silence 1 0.1 0% reverse

先頭末尾のフレーム処理

# 190フレーム無音ファイル作成
$ sox -n -b 16 silence.wav rate 16k channels 1 trim 0.0 0.19
# 先頭へ190フレーム無音区間追加
$ sox silence.wav input.wav outputH190.wav

# 80フレームトリム
$ sox input.wav outputT-80.wav trim 0.0 0.87

ホワイトノイズの重畳

# ホワイトノイズ作成
$ sox -t null /dev/null whitenoise_raw.wav synth 0.87 whitenoise 10000 gain -20
$ sox whitenoise_raw.wav -b 16 whitenoise.wav channels 1 rate 16k
# ホワイトノイズ重畳
$ sox -m input.wav whitenoise.wav output.wav
2
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?