Skip to content

オーディオスペクトラムや波形をOpenCVで、はめ込み描画するサンプル

License

Notifications You must be signed in to change notification settings

Kazuhito00/Overlay-Audio-Spectrum-Using-OpenCV

Repository files navigation

Overlay-Audio-Spectrum-Using-OpenCV

オーディオスペクトラムや波形をOpenCVで、はめ込み描画するサンプルです。
Draw-Audio-Spectrum-Using-OpenCVcv_overlay_inset_imageを用いています。

Demo.mp4

Requirement

opencv-python 4.5.5.62 or later
PyAudio 0.2.11         or later

Contents

No.0
No.1
No.2
No.3
No.4

Usage

デモの実行方法は以下です。

python demo.py --wave=[Your wav file]
  • --bg_image
    背景画像のパス指定
    デフォルト:sample.jpg
  • --bg_movie
    背景動画のパス指定 ※指定時はbg_imageより優先
    デフォルト:指定なし
  • --bg_device
    背景用Webカメラ画像のデバイス指定 ※指定時はbg_imageより優先
    デフォルト:指定なし
  • --wave
    Waveファイルの指定 ※指定時はマイクデバイスより優先
    デフォルト:指定なし
  • --frames
    フレーム読み出し数
    デフォルト:2048
  • --fft_n
    FFTポイント数
    デフォルト:1024
  • --draw_type
    Contentsの描画種別
    デフォルト:0
  • --color
    重畳描画するオーディオスペクトラムや波形の色指定
    デフォルト:指定なし ※指定時はBGRで255,255,255のように指定
  • --border_color
    warpPerspectiveの境界の色
    デフォルト:0,0,0

Author

高橋かずひと(https://twitter.com/KzhtTkhs)

License

Overlay-Audio-Spectrum-Using-OpenCV is under Apache-2.0 license.

また、サンプル画像はフリー素材ぱくたそ様の
ずっと使われていない天井吊りのテレビの写真素材」を利用しています。

About

オーディオスペクトラムや波形をOpenCVで、はめ込み描画するサンプル

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages