While the PS3 has native support for playing standard WMA music files, it does not support the WMA Lossless format. My music library is ripped to WMA Lossless, so I wanted to find a way to stream the collection to my new PS3 Slim. Fortunately, the open source PS3 Media Server project makes this almost painless.
Although I rip my CD collection on a Windows machine, the collection itself is stored in a shared folder on a Mac mini. I run a slightly modified version of the FireFly Media Server (aka mt-daapd) on the Mac to serve this collection to any computer running iTunes, as well as a few Roku SoundBridge devices in the house. Since none of the clients support WMA Lossless, I have FireFly configured to use mplayer [mplayer, mplayersilent] to transcode the WMA Lossless files to WAV files on the fly. This scheme works great, provided you have a build of mplayer that can decode WMA Lossless. I use the build from here: http://stefpause.com/apple/mac/mplayer-os-x-10rc1-and-mencoder-binaries/
Installing and running PS3 Media Server on a Mac is a simple and painless way to serve media remotely to a PS3. And it too uses mplayer to transcode audio files. However, when I tried to serve WMA Lossless files from PS3 Media Server to my PS3, I got an “unsupported format” error.
It turns out that (as of this writing) PS3 Media Server includes its own build of mplayer, and that build does not support WMA Lossless. Fortunately, this is easy to fix if you have another version of mplayer installed. Just open a Terminal window, head to the “osx” directory within the “PS3 Media Server.app” resources directory, and create a symlink to the correct version of mplayer.
Here are the basic steps:
1) Install mplayer from here: http://stefpause.com/apple/mac/mplayer-os-x-10rc1-and-mencoder-binaries/
2) Start the Terminal app, and enter the following commands in order:
cd /Applications/PS3 Media Server.app/Contents/Resources/Java/osx
sudo mv mplayer mplayer-old
ln -s /usr/local/bin/mplayer mplayer
That’s all there is to it. PS3 Media Server will automatically serve and transcode WMA Lossless files for the PS3.
PACPL, the Perl Audio Converter, is a great Perl script that will batch transcode audio files from one format to another. For a variety of reasons, my music library is in the WMA Lossless format, and I wanted to use PACPL to transcode the WMA files to MP3. By default, PACPL does not support transcoding of WMA Lossless files, so I patched the script to add the support. While I was under the hood, I added support for the “Composer” and “Album Artist” meta tags for WMA decoding and MP3 encoding. The Album Artist tag helps media players like iTunes group songs by album, even if there are different performers. I also added support for embedding album art into MP3 files.
PACPL normally uses ffmpeg to decode WMA files, but ffmpeg does not support WMA Lossless. With the patch, PACPL has the option to use mplayer to decode WMA files. This works fine, with one exception. Some versions of mplayer (like the one I use: 1.0rc1-4.1.2) have a bug that prevents it from properly creating files with commas in the filename or path. I added options to remove commas from decoded filenames and to use the /tmp directory for decoding. Edit the script and set both options to 1 if you have problems with mplayer.
# decoding options for temp files
# use /tmp/ directory for temporary decoded .wav files
my $decode_usetmp = 0;
# replace commas in decode filename to work around mplayer bug
my $decode_replacecommas = 0;
For embedded album art, I added a command line option --albumart= to specify the source album art JPG file name. It expects a JPG file that is in the same directory as the source audio files. If it finds the JPG, it will embed the image into the MP3 header. I did not add album art support to any other output formats, though it should be easy enough to do if their Perl modules support it.
I ended up learning more about the MP3 ID3 metadata format than I intended. What a mess. Fortunately, the MP3::Tag module is pretty robust. That said, I did find a bug. The test file I used was a Stevie Ray Vaughan song, which has the genre “Blues.” This is the first genre in the ID3 genre list, and has the ID of 0. For the life of me, I couldn’t figure out why the script was losing the genre tag until I realized that a genre ID of 0 was getting skipped by MP3::Tag. I added a workaround to change the Blues genre name to be “Blues & Roots”, which forces the genre to be encoded as a string instead of ID number.
I also found that different media players treat album art in different ways. That is, some players are very forgiving of bad metadata headers, while others are not. I tested album art in iTunes, Foobar 2000, Windows Media Player, VLC, Winamp, and Amarok. For reference, here’s the magic header for JPG album art that works with all of the tested media players:
# important to set unsync to false, otherwise ID3v2 data can appear "corrupt"
MP3::Tag->config("id3v23_unsync_size_w",0);
MP3::Tag->config("id3v23_unsync",0);
$tag_m = MP3::Tag->new("$out_file");
# ID3v2 Tags
unless(exists($tag_m->{ID3v2})) { $tag_m->new_tag("ID3v2"); }
$tag_m->{ID3v2}->add_frame("APIC", "\x00", "image/jpeg", "\x03", "Cover (front)", $imagedata);
With my patches, here’s the shell command I use for transcoding a directory tree of WMA Lossless files to high-bitrate mp3 files:
pacpl -v -t mp3 -r -p -o wma --albumart="Folder.jpg" --defopts 0 --eopts="-q 0 -v -V 0 -b 320 -F" --decoder mplayer /music/WindowsMedia/ --outdir /music/mp3/
Unfortunately, I stink at Perl, so a lot of my Perl code looks like C. I tested the patches on my personal WMA Lossless collection on two different installs of ZenWalk Linux. Therefore, I hereby grant this code the honorary Scott Hanselman badge of “Works on My Machine.”
You can download the patched Perl script here: pacpl-wmal-patched.tar.gz
I’ll send the patches up to the maintainer of PACPL, but I’m not sure if he’s interested (or if he’ll recoil in horror at my code). I’ll add a comment if I hear back from him.
UPDATE: Turns out that I accidentally switched the Artist and Album Artist metadata tags, which is critical for iTunes. I fixed it and re-uploaded the tarball.
I still buy CDs. And until Amazon.com or iTunes starts selling music in a lossless format, I’ll likely continue to do so. However, I rip CDs to my PC immediately after purchase, leaving me with the problem of where to store the CD. Dumping the CD jewel case and storing just the CD and liner notes can save a ton of space, so I decided to buy some thin CD sleeves.
You can buy plain paper CD sleeves from numerous sources, but they usually don’t have room for liner notes. There are also many CD cases with built-in sleeves available, but they’re usually pretty crummy. The sleeves are often made of cheap plastic that tears easily, and can stick to the CD. They rarely have a slot for the liner notes, and you can’t remove the sleeves from the case.
Slappa makes the best CD sleeves I’ve found. Each sleeve has a fabric slot for the CD and another slot with a matte polypropylene clear cover for liner notes. They are stitched around the sides instead of glued or melted, so they won’t come apart over time. They have an optional interlocking slot system that let’s you easily remove and re-sort a CD collection. A single sleeve holds two CDs and two liner notes, and Slappa sells a model that holds four CDs for two double-CD sets. These things are fantastic.
I intended to buy the sleeves on their own, but it was a tad cheaper to buy them with an included case. The cases are impressive too – very rugged. There is a pocket in the front of the case that I use to store the back sides of CD inserts.
Slappa also makes a version of the sleeves for DVDs. I bought a set of them and tossed the original cases for a bunch of movies and video games. It’s amazing how many DVDs and video games you can store in a single drawer after ditching their cases.
I ordered everything directly from the Slappa web site, but it looks like they are now also available on eBags.com, possibly with cheaper shipping.
The only downside is what to do with the leftover CD jewel cases. It turns out that they are very difficult to recycle, and can’t be put in the recycling bin. Apparently, you can mail them to a couple of companies who will then try to re-sell them or grind them up, but I’m not sure I want to pay to mail hundreds of empty cases somewhere. If you know of any ideas, please post a comment.
Obviously, you can't have a good whole-house music system [musicstorage4, musicstorage6, musicstorage1, musicstorage2, musicstorage-solved3, musicstorage3, musicstorage-solved1, musicstorage8, musicstorage-solved2, musicstorage5, musicstorage7] without some dedicated music-playing hardware. In choosing a music player, I gave myself the following requirements:
The only music player that hit the sweet spot of these requirements was the Roku SoundBridge. The SoundBridge is a wonderful little music player that can exist in a number of network, OS, and server configurations. It is quite future-proof.
Natively, the SoundBridge can decode MP3, WMA, AAC, and Apple Lossless audio formats. However, it also supports uncompressed .WAV files, which allows for real-time server-side transcoding of any other audio format, such as WMA Lossless or FLAC.
The SoundBridge also supports two widely used server protocols: UPnP/DLNA, and iTunes, both of which are widely available on almost all platforms. It works perfectly with Windows Media Player 11 sharing as well as Apple's iTunes sharing.
The latest firmware for the SoundBridge adds a feature that I never expected to want, but I use all of the time: Internet Radio. Roku maintains a large database of various audio streaming sites, and presents them in an easy-to-navigate format on the SoundBridge. This setup beats the pants off the local radio stations and cable TV music channels.
And finally, the sound quality is outstanding. I rip all of my music from CDs in lossless audio formats, and playback on the SoundBridge is absolutely perfect.
The only downside I've noticed is that once every few months, the SoundBridge will stop connecting to the server. I suspect this is related to my network's wireless configuration. To fix the problem, I simply restart the SoundBridge using the "restart" option on the menu. It only takes a few seconds, so this is more of an annoyance than a major issue.
I have 3 SoundBridges on my network at home, an M1000 and two M500's. Roku sells the latest SoundBridge M1001 on their site, but you can find M500's and M1000's pretty easily on eBay. And if you can get the large-screened M2000, all the better. Audiophiles might actually prefer the older units, as they pass bitstreams in their native resolution, whereas the M1001 upconverts all audio to 48Khz. Most users, however, probably won't notice the difference.
In summary, I highly recommend the Roku Soundbridge as a dedicated music player for a whole-house music system.
A key component in my whole-house music system [musicstorage4, musicstorage6, musicstorage1, musicstorage2, musicstorage-solved3, musicstorage3, musicstorage-solved1, musicstorage8, musicstorage-solved2, musicstorage5, musicstorage7] is a media player on Windows. While I run both Windows and Linux (and soon Mac) at the house, Windows XP is my primary OS.
I found that there is no single media player that meets all of my requirements. I tried tons of various media players, including oldies like WinAmp, and cool new ones like MediaMonkey, foobar2000, and KMPlayer. But I ended up going with two predictable choices: Windows Media Player 11 and iTunes. And of the two, I much prefer WMP11.
My choice of media player came down to the following requirements:
WMP11 is the clear winner in almost every category:
With an iPod/WMP11 plugin such as dopisp, WMP11 can even sync with my iPod nano. However, as I'll explain in a future post, WMP11 can only manage a single "library" at once, which prevents me from using it as my iPod manager. This is fine, as iTunes is still the best iPod manager available, and does a superb job of maintaining podcast subscriptions.
So there you go: my primary media player for my whole-house music solution is Windows Media Player 11… with a little help from iTunes.