Created
January 9, 2013 14:53
-
-
Save anonymous/4493711 to your computer and use it in GitHub Desktop.
Using pyglet to play a file. You require avbin installed from their site and the following packages in Ubuntu: python-pyglet libglu1-mesa-dev freeglut3-dev mesa-common-dev libopenal-dev libalut-dev
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import pyglet | |
mp3 = "test.mp3" | |
source = pyglet.media.load(mp3) | |
player = pyglet.media.Player() | |
player.queue(source) | |
player.play() | |
pyglet.app.run() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment