Album art, Ogg Vorbis #android #music

๐Ÿ•›๏ธŽ - 2012-02-23

It seems that getting album art to show up for Ogg Vorbis files is an ongoing struggle on every phone I get.

At least the source code for Android seems to be readily available.

So, first clue: in 2009 code was removed from src/com/android/music/MusicUtils.java that would read AlbumArt.jpg: "Remove code for getting and saving album art from the music app and use the media provider instead.".

Which probably means that I should go hunting in the media provider for more clues.

It looks like it does scour the filesystem for albumart.jpg - so why doesn't it work?!?


Update: Ok, it seems to work if the albumart.jpg file is there from the beginning. It doesn't seem to work to add it later, not even if I remove the entire directory and then copy it back.

I wonder how I can "flush the album art cache".

Update 2: Looks like adding albumart.jpg before transferring the files to the phone and having the image square (NxN pixels) works.

Update 3: If the phone has decided that the albumart isn't there, it seems a reboot is needed to change that decision (at least; clearing Music data might also be needed; moving the files off+back on is not necessary).

Update 4: The image doesn't have to be square - I just got three images that are higher than they are wide to show up, so I am down to Android being picky about the JPEG-format; opening the image in Gimp and saving it again seems to help (with a clear Music data (possibly) and a reboot (for sure) afterwards).

Also, did you notice that the stock ringtones, notification-, and alarm-sounds are all Ogg Vorbis files? Nice touch.

It does indeed help to clear Music data. Thanks for solving this highly annoying problem!

- Klaus Alexander Seistrup ๐Ÿ•™๏ธŽ - 2012-03-04


It is one of those things that is just mind bogglingly boring to mess around with!

Now I just need the clock to add a count down feature, and the email client to allow proper non-TOFU quoting, and I'm pretty happy.

- Adam ๐Ÿ•œ๏ธŽ - 2012-03-04


Add comment

To avoid spam many websites make you fill out a CAPTCHA, or log in via an account at a corporation such as Twitter, Facebook, Google or even Microsoft GitHub.

I have chosen to use a more old school method of spam prevention.

To post a comment here, you need to:

ยน Such as Thunderbird, Pan, slrn, tin or Gnus (part of Emacs).

Or, you can fill in this form: