Giter Site home page Giter Site logo

id3img's Introduction

id3img

This is a simple web server that works with MPDroid so that you can see the album art for your music.

By default, MPDroid will pull images from Last.fm, which is OK, but doesn't always get exactly the right image. So there is an alternative configuration (see "Download local cover art" in the settings) that allows you to pull images from a "web server" - id3img provides a suitable web server.

id3img provides images from four different sources:

  • from /root/artist/album/folder.jpg - this assumes that each album directory contains an image with a fixed name (by default folder.jpg, but you can change it in MPDroid's settings).

  • from an ID3 PIC or APIC tag in any /root/artist/album/*.mp3 - so if any mp3 in that directory contains an image in the ID3 data, then that image will be used.

  • from /root/Various/album/folder.jpg - as above (fixed name file), but maybe the album is a collection from various artists.

  • from an ID3 PIC or APIC tag in any /root/Various/album/*.mp3 - as above (ID3 image), but maybe the album is a collection from various artists.

In the examples above, /root is the path that you give to the id3img server on the command line when you start the program (see below). The values of artist and album are taken from the music that is being played. An alternative for folder.jpg can be set in the MPDroid settings.

Limitations

This is Python code, not packaged in anyway, so you need to be able to install Python software from Github and be comfortable with getting it running.

It has been tested only on Linux, with Python 3 (it will not work with Python 2 - come on, it's 2013 already).

Everything assumes that the music is grouped in directories by artist name and then album name.

IMPORTANT - this program provides access to files on your computer. A remote user can request any file, by giving the appropriate path. So you should only use it on a local network where you trust other users. (In theory, only files below the directory containing music - the path given on the command line at startup - are available, but there may be bugs in the code.)

Installation

  1. Make sure that you have Python 3 (tested with Python 3) available.

  2. Clone this git repo.

  3. If you want, you can use the setup-env.sh script to create a virtualenv environment.

  4. Run the server. For example,

    PYTHONPATH=src python3 src/id3img/server.py /music/mp3

    For help on options, see python3 src/id3img/server.py -h.

  5. Configure MPDroid. You will likely want to change the "path to music" to be something like http://your.machine:6601/.

Debugging

You can enable debug logging (to stderr) with:

PYTHONPATH=src python3 src/id3img/server.py -l DEBUG /path/to/music

Don't forget to open port 6601 (or whatever value you configure with -p) in your firewall.

Licence

Code is (c) Andrew Cooke 2013, but released into the public domain with absolutely no warranty. So you can do what you like with it. Just don't sue me.

Stagger

This software includes a copy of Stagger which appears to be no longer maintained, and does not install. The copyright remains with the initial author, Karoly Lorentey. See LICENCE file in the stagger directory.

id3img's People

Contributors

andrewcooke avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

id3img's Issues

"ImportError: No module named 'stagger'" when trying to run the server.

Hi,

When I try to run id3img on my arch linux laptop, I get the following:

jorge@flamingo:~/Tmp/id3img$ python3.5 src/id3img/server.py /home/jorge/Multimedia/Audio
Traceback (most recent call last):
File "src/id3img/server.py", line 10, in <module>
from stagger import read_tag
ImportError: No module named 'stagger'

Could you please advise?

Many thanks in advance.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.