LoginSignup
1
0

More than 1 year has passed since last update.

WSLでpythonを使ってmp3を再生する

Last updated at Posted at 2023-03-13

WSLで音を鳴らしたいときはffmpegとpydubを使いましょ。めっちゃ簡単に鳴らせます。

sudo apt install ffmpeg
pip install pydub
from pydub import AudioSegment
from pydub.playback import play

sound = AudioSegment.from_mp3("./music.mp3")
play(sound)
1
0
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
1
0