Wie man mit pydub spielt.
play.py
#! /usr/bin/python
#
# play.py
#
# Oct/06/2020
#
# ------------------------------------------------------------------
import sys
from pydub import AudioSegment
from pydub.playback import play
# ------------------------------------------------------------------
sys.stderr.write("***Start***\n")
#
file_in = sys.argv[1]
audio_aa = AudioSegment.from_wav(file_in)
play(audio_aa)
#
sys.stderr.write("***Ende***\n")
# ------------------------------------------------------------------
Ausführungsmethode
./play.py input.wav
Recommended Posts