Posts Tagged Mp3

The Random Album Chooser, now with integral playback

I know I said I wasn’t going to update the Random Album Chooser any more in my last post but:

a)  I’ve not had much time to work on the WPF version and I still haven’t come up with a new navigation model I like; and more importantly:

b) Windows Media Player can’t cope with UTF8 characters in .mu3 files.

How do I know this? Well I had an e-mail from a user (yes hard to believe I know, but it does happen) who was initially having problems installing the application, but then once that was sorted got an error when sending the playlist to Windows Media Player. I tried some albums of mine and everything seemed OK, then I realised that the user was Spanish so there was a high likelihood of there being UTF8 characters in the filenames. So I tried a file and got the following error:

Windows Media Player error

Windows Media Player error

While diagnosing the initial problem I contacted a friend to try the install and he suggested that I add integral playback. I was initially sceptical, but the playlist problem convinced me so I used the Windows Media Player library (more information on the MSDN) to implement simple playback controls.

  • Alt+P will now pause while currently playing as well as play.
  • Alt+J while playing skips back to the previous track.
  • Alt+L while playing skips forwards to the next track.
  • Alt+K stops the playback and resets back to the start of the current album.

I also implemented popup notification of currently playing track when the track changes, show the current track on right click over the cover art and automatically choose the next album when this one finishes. I didn’t implement auto play at this stage – this has just occurred to me as a possible enhancement. I can see that this might be useful I’ll add it to the “to do” list.

Currently there’s no UI on the playback controls other than clicking the cover art to play/pause. I don’t really know where these would go best so I thought I’d leave it off for now.

There are a number of other changes in this version as well:

  • Titles and Artists with “&” not displayed correctly in details popup (right click over album cover).
  • Fixed problem with Unicode characters in Tracks/Artists.
  • Application location now saved correctly if closed from minimized state.

Download it now or if you’ve already got it installed it should update automatically the next time you start the application. There was a problem with the version I uploaded last week – a simple coding error as it turned out – and nothing to do with 64 bit Window 7 at all.

So, I’m not going to promise that the next version will be the WPF version as that’s just setting myself up to fail.

© 2011, Chris. All rights reserved. If you republish this post can you please link back to the original post.

, ,