Skip to content

Instantly share code, notes, and snippets.

@Racum
Created July 11, 2013 18:40
Show Gist options
  • Save Racum/5978005 to your computer and use it in GitHub Desktop.
Save Racum/5978005 to your computer and use it in GitHub Desktop.
# Download this example file first:
# http://podcast.cbc.ca/mp3/podcasts/spark_20130623_97794.mp3
import cStringIO as StringIO
from PIL import Image
import eyed3
audiofile = eyed3.load("spark_20130623_97794.mp3")
if len(audiofile.tag.images) > 0:
stream = StringIO.StringIO(audiofile.tag.images[0].image_data)
image = Image.open(stream)
image.show()
else:
print 'No cover art.'
Paver==1.2.1
Pillow==2.1.0
eyeD3==0.7.2
wsgiref==0.1.2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment