Skip to content

romanin-rf/playsoundsimple.py

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

45 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

playsoundsimple.py

Description

Library for working with sound files of the format: MP3, WAV, OGG,FLAC, MIDI.

Installation

pip install playsoundsimple.py

About MIDI support

In order to play MIDI files you need to install FluidSynth:

  • Windows: Releases
    1. Download a zip file suitable for your version of Windows.
    2. Unpack the archive anywhere, but it is recommended to put it in a folder C:\Program Files\FluidSynth
    3. Next, open Settings > System > About the system > Additional system parameters > Environment variables > [Double click on Path] > Create > [Enter the full path to the folder with FluidSynth]
    4. That's it, FluidSynth is installed!
  • Linux:
    • Ubuntu/Debian:
      sudo apt-get install fluidsynth
    • Arch Linux:
      sudo pacman -S fluidsynth
  • MacOS
    • With Fink:
      fink install fluidsynth
    • With Homebrew:
      brew install fluidsynth
    • With MacPorts:
      sudo port install fluidsynth

More

import playsoundsimple as pss

s = pss.Sound("main.wav")
s.play()
s.wait()

Author