Friday, January 06, 2006

Suuurrrooouuunnnnd

Santa Claus brought me a brand new Creative Sound Blaster Audigy card along with 5.1 speakers. I wasn't looking for a new sound card, but now I really love the sound I can get here...
I first installed the windows drivers, which confirmed the nice surround sound quality :)
I was a bit curious how Linux would handle the card, and specifically the 5.1 speakers. I had a few problems (and still have) with the Alsa drivers, but curiously not at first. The problem only manifests when I boot my PC directly in Linux (which I do most of the time). Instead of crystalline sound I got some horrible noise. However, if I first boot Windows and then reboot to Linux, everything is fine. It appears to be some kind of initialization code that is missing from the Alsa drivers.

Besides that annoyance (which I hope it ends soon), the sound in Linux is now a lot better than before. One of the first things I tried was to listen to the surround sound in a DVD. I had a few problems configuring Xine, but it worked nice on Mplayer. And yes, the sound is great :)
However, I noticed something missing comparing to windows drivers. When listening to music, I realized the music was playing only on the 2 front speakers. And in windows, besides playing on all 6 speakers, I could also select from a set of special effects (like the sound was playing inside a church, auditorium, etc). Of course, I wasn't hoping to have those special effects in Linux...and I don't miss them too. It's fun to try the first time, but who uses them, really ? :)
What bothered me was that the music didn't play on all 6 speakers. Well, I never thought about how things were done in Windows, but I soon figured why Linux only plays on 2 speakers. A surround sound (one that plays on all 6 speakers) must have the information on what to play on each speaker. The sounds and music on DVD are recorded in 6 channels....one for each speaker. But normal music is record in Stereo, which means 2 channels. So, normal music should be played only on 2 speakers. Fortunately there's a trick: I could tell it to play the same channel on several speakers. That's very easy to do in Alsa. However, it doesn't sound the same as in Windows. What I think Windows drivers do is apply some kind of audio filter to the duplicated channels. That filter gives the sound a more 3Dish feel. Nevertheless, the result is reasonable. And hopefully someone with time and patience creates a similar set of functions to be added transparently to Alsa (instead of specific to each driver), which would make it very flexible.

It's amazing how much we can do in Linux, even when we lack the manufacturer's drivers ;)