larryni.me.uk

Computers, gadgets, music, Derry and general random stuff
  • rss
  • Home
  • About
  • Contact

Display Amarok album art in Conky

Laurent | October 18, 2009 | 10:07 am

The latest versions of Conky can be used to not just display text but also images, amongst other cool stuff like drawing gauges and use Lua scripts.  I’d been using it for quite some time to display track information from Amarok. Now I finally have a way to display cover art as well.

Conky displaying Amarok album art - work in progress

If you’re already running Karmic then you can install the latest version from the repositories. Install the conky-all package which has most compile options enabled to get the latest features. You’ll also need imagemagick installed.

First we need a script to fetch the cover and convert it into an album stack. The angle of the covers changes slightly with each track. It also resizes each stack to 150×150. Click here and save it as ~/bin/getcover. As you can see I had some help with it – thanks to eightmillion from the Ubuntu forums for completely rewriting it to something useable ;)

Next get the script to pull the rest of the track info from Amarok – click here and save as ~/bin/askamarok. Try it from the command line whilst Amarok is playing, e.g. to get the artist name enter

askamarok artist

Other available info is title, album, year, genre, bitrate, track playing time, total track playing time… You can also get collection info and stats. For the stats Amarok needs to store the collection in a MySQL database.

Finally get my Conky script and save as ~/conkycover. To run it:

conky -c conkycover

If it’s the only Conky script you’re running then save it as ~/.conkyrc and start Conky without any options.

Last thing missing is the cover when Amarok is not actually running. Save the following image as ~/conky/cover/noplay.png:

noplay

The whole thing is a bit rough. For example, not all the info updates at the same time on track changes. And although I set the update interval for the playing times to 1 second it leaves 3 seconds in between. It also does not look the best when no track is playing, or Amarok is not running. Feel free to post any improvements/ideas in the comments as my Conky layout skills leave a lot to be desired ;)

Share it:
  • Twitter
  • Identi.ca
  • Facebook
  • MySpace
  • Tumblr
  • Ping.fm
  • StumbleUpon
  • FriendFeed
  • email
  • Google Bookmarks
  • del.icio.us
  • Add to favorites
Categories
Linux, Ubuntu
Comments rss
Comments rss
Trackback
Trackback

« My Karmic desktop Configure PulseAudio for Skype to work with your USB handset »

Other posts that might interest you

  • Access Google Calendar from the Command Line
  • Organise your music collection with EasyTAG
  • Add/remove Gnome desktop icons
  • 4 responses

    [...] http://www.larryni.me.uk/blog/2009/10/18/display-amarok-album-art-in-conky/

    Laurent (larryni) 's status on Sunday, 18-Oct-09 10:33:27 UTC - Identi.ca | October 18, 2009 | 10:33 am | Comment reply:Reply to this comment

    [...] http://www.larryni.me.uk/blog/2009/10/18/display-amarok-album-art-in-conky/ a few seconds ago from web [...]

    [...] This post was mentioned on Twitter by larryni, alex

    Tweets that mention Display Amarok album art in Conky | larryni.me.uk -- Topsy.com | October 18, 2009 | 11:41 am | Comment reply:Reply to this comment

    [...] This post was mentioned on Twitter by larryni, alex knorr. alex knorr said: RT @hashlinux: here's the instructions/scripts for #amarok covers in #conky http://bit.ly/2gaET3 #linux #ubuntu(via @larryni) [...]

    nice work! does it work with amarok 1.4? because i

    matef | February 16, 2010 | 11:08 pm | Comment reply:Reply to this comment

    nice work! does it work with amarok 1.4? because i can’t get it working…

    It only works with 1.4. I should have mentioned that

    Laurent | February 16, 2010 | 11:48 pm | Comment reply:Reply to this comment

    It only works with 1.4. I should have mentioned that in the post.

    How is it not working for you?

    Leave a comment

    You can use these tags : <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

    Note: If your comment contains 3 or more URLs I will need to approve it first. Sorry about his, but the spammers are trying to take over.

    Categories

    Archives

    Recent Posts

    • How to get the HTC Tattoo to scan QR codes
    • The Rolling Stones/Stevie Wonder – Uptight/Satisfaction (1972)
    • Balloon Bass
    • Finished Wordpress upgrade
    • Configure PulseAudio for Skype to work with your USB handset
    • Display Amarok album art in Conky
    • My Karmic desktop
    • Set up a VPN in Ubuntu with an itshidden.com account

    Random snaps on Flickr

    www.flickr.com

    Music

    • Discogs
    • Jamendo
    • last.fm
    • Musicbrainz
    • Pandora
    • SomaFM
    • Whole Wheat Radio

    Music Blogs

    • Chocoreve
    • Lost-In-Tyme
    • O CANADARM!
    • Office Naps

    Podcasts

    • Americana Roots
    • BBC Digital Planet
    • GaragePunk
    • Linux Reality
    • National Geographic
    • Roots Rock Radio Show
    • The Skeptics’ Guide to the Universe
    • Tom Fahey’s AmericanaOK
    • Ubuntu UK podcast

    Meta

    • Log in
    • Entries RSS
    • Comments RSS
    • WordPress.org

    Visitor Map

    Locations of visitors to this page

    Miscellaneous

    • Computer Blogs - BlogCatalog Blog Directory
    • Irish Blog Directory
    • Add to Technorati Favorites
    • Irish Blogs Directory
    rss Comments rss valid xhtml 1.1 design by jide powered by Wordpress get firefox