LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 08-05-2006, 06:46 PM   #1
conanm4
Member
 
Registered: Aug 2006
Distribution: Ubuntu Gutsy, Slackware 12.1 (soon)
Posts: 25

Rep: Reputation: 15
surround sound


Does anyone know of a distro that has good 5.1 surround sound support, Ubuntu will only detect 2 of my 5 speakers and sub. I have a CMedia sound card and the Logitech X-530 speakers.
 
Old 08-05-2006, 07:25 PM   #2
Electro
LQ Guru
 
Registered: Jan 2002
Posts: 6,042

Rep: Reputation: Disabled
Any Linux distribution have the same problems with surround sound. You will have to either edit/create $HOME/.asoundrc to create simulated surround sound from two channel sources or play movies that have surround sound included in the audio track. Some music CD/DVD includes surround sound but they are either simulated surround sound or special software you have to use to decode the sound. Though if you use $HOME/.asoundrc to created simulated surround sound, the subwoofer channel will still output the full range of frequencies. This means you need an active low-pass filter between the sound card and subwoofer amplifier.

The lines to put in $HOME/.asoundrc.
Code:
pcm.simulatedsurround51 {
    type route
    slave {
        pcm 'hw:0,0'
        channels 6
    }
    ttable.0.0 0.9
    ttable.1.1 0.9
    ttable.0.2 0.75
    ttable.1.3 0.75
    ttable.0.4 0.5
    ttable.1.4 0.5
    ttable.0.5 0.5
    ttable.1.5 0.5
}

ctl.simulatedsurround51 {
    type hw
    card 0
}

pcm.simulatedsurround40 {
    type route
    slave {
        pcm 'hw:0,0'
        channels 4
    }
    ttable.0.0 1
    ttable.1.1 1
    ttable.0.2 0.75
    ttable.1.3 0.75
}

pcm.simulatedsurround41 {
    type route
    slave {
        pcm 'hw:0,0'
        channels 6
    }
    ttable.0.0 1
    ttable.1.1 1
    ttable.0.2 0.75
    ttable.1.3 0.75
    ttable.4.4 0
    ttable.0.5 0.5
    ttable.1.5 0.5
}

ctl.simulatedsurround51 {
    type hw
    card 0
}

ctl.simulatedsurround40 {
    type hw
    card 0
}

ctl.simulatedsurround41 {
    type hw
    card 0
}
The above code uses the route library to copy and lower the volume when told to do so. The rear and front channels are lowered for 5.1 setups to produce a sense of multiple channels and ambient sound. The voices will seem to be heard from only the center channel even though the left and right front channels are producing it too. In the 4 channel setup, subwoofer is left out and the difference in channels can be more defined. The 4 channel setup will add better transients and spacious because the subwoofer is left out. The 4.0 channel setup is better for music. The 4.1 setup includes a subwoofer. This setup is much better for movies and satellite/subwoofer setups.
 
Old 08-05-2006, 07:32 PM   #3
conanm4
Member
 
Registered: Aug 2006
Distribution: Ubuntu Gutsy, Slackware 12.1 (soon)
Posts: 25

Original Poster
Rep: Reputation: 15
So do I create that file in my home folder or do I create a $HOME folder and if so where do I put that?
 
Old 08-07-2006, 05:49 PM   #4
zhangmaike
Member
 
Registered: Oct 2004
Distribution: Slackware
Posts: 376

Rep: Reputation: 31
HOME is an environment variable which contains the path to your home directory. $HOME will be replaced by the shell by the contents of this variable.

For example, the main user on my system is zmk, with the home directory /home/zmk. For that user,

$HOME/.asoundrc

is the same as:

/home/zmk/.asoundrc
 
Old 08-10-2006, 02:19 PM   #5
conanm4
Member
 
Registered: Aug 2006
Distribution: Ubuntu Gutsy, Slackware 12.1 (soon)
Posts: 25

Original Poster
Rep: Reputation: 15
Didn't do anything
 
Old 08-10-2006, 06:32 PM   #6
Napalm Llama
Member
 
Registered: Nov 2004
Location: Bristol, UK
Distribution: Gentoo 2005.0
Posts: 224

Rep: Reputation: 30
Have a look here:

http://gentoo-wiki.com/HOWTO_Surround_Sound

I wouldn't recommend Gentoo itself to you just yet (give it a few months), but that HOWTO got my 7.1 setup working very nicely indeed, thankyou.

Everyone's .asoundrc is a little bit different, so I wouldn't recommend copying directly off anyone else (no offence, Electro [apologies for putting the wrong name here earlier]) - if you're up to it, that HOWTO should give you the information you need to set one up of your own.

As a side note, http://gentoo-wiki.com is an excellent resource for all number of Linux things - and while it is obviously Gentoo-centric, it can be an invaluable guide no matter what distro you use.

Last edited by Napalm Llama; 08-13-2006 at 06:35 AM.
 
Old 08-10-2006, 11:21 PM   #7
conanm4
Member
 
Registered: Aug 2006
Distribution: Ubuntu Gutsy, Slackware 12.1 (soon)
Posts: 25

Original Poster
Rep: Reputation: 15
surround sound

alright I almost have it working, the only problem is on surround sound in the alsa mixer it only lets me choose the rear left or the rear right. It won't let me have both. Any ideas?
 
Old 08-10-2006, 11:25 PM   #8
conanm4
Member
 
Registered: Aug 2006
Distribution: Ubuntu Gutsy, Slackware 12.1 (soon)
Posts: 25

Original Poster
Rep: Reputation: 15
nvm

scratch that i'm set, i'm so happy! Thanks for the gentoo link
 
Old 08-11-2006, 12:01 AM   #9
WhiskeyTangoFoxtrot
Member
 
Registered: Oct 2005
Location: Windsor, Ontario, Canada
Distribution: Fedora Core 5,4,3 & Ubuntu 6.06, 8.10
Posts: 403
Blog Entries: 1

Rep: Reputation: 30
i have the same speakers and sound card ( 4-channel one ) and i was able to get 4.1 sorround working. all i did was double click on the speaker vol button in the taskbar and tell the volume controller to add the 3d sorround buttons for the CMedia card. after that i just turned it on and now the front and rear speakers are working fine. thats for Fedora though.......
 
Old 08-11-2006, 01:26 AM   #10
Electro
LQ Guru
 
Registered: Jan 2002
Posts: 6,042

Rep: Reputation: Disabled
Real surround sound is not all channels with the same volume. It is actually all channels have their own volumes. Normally the center channel is the dominate channel. The front left and right channels provides stage shifting but their volume are lower than the center channel. The rear channels provides ambient sound. These speakers should never be directed to the listening area. A lot of people set up the rears like they do for the fronts which is wrong. The rears have to create a null to the listening area to not be as bright as the fronts but reflected and reverb sound. To do this is easy. Direct the rears away from the listening area but at a diffused material. You will still hear the ricochet from the rears but it will produce better results.

The lines that I provided for $HOME/.asoundrc provides the best simulated surround sound from a stereo source even with out reverb and reflection. The lines from the gentoo-wiki site provides wrong surround sound setup because they use duplicate which copies and keeps the same volume for all channels. This gets the job done but it is lazy although my lines are much better. Of course you need to tweak the lines a little bit to make it work for your sound card.
 
Old 08-11-2006, 06:13 AM   #11
conanm4
Member
 
Registered: Aug 2006
Distribution: Ubuntu Gutsy, Slackware 12.1 (soon)
Posts: 25

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by Electro
Real surround sound is not all channels with the same volume. It is actually all channels have their own volumes. Normally the center channel is the dominate channel. The front left and right channels provides stage shifting but their volume are lower than the center channel. The rear channels provides ambient sound. These speakers should never be directed to the listening area. A lot of people set up the rears like they do for the fronts which is wrong. The rears have to create a null to the listening area to not be as bright as the fronts but reflected and reverb sound. To do this is easy. Direct the rears away from the listening area but at a diffused material. You will still hear the ricochet from the rears but it will produce better results.

The lines that I provided for $HOME/.asoundrc provides the best simulated surround sound from a stereo source even with out reverb and reflection. The lines from the gentoo-wiki site provides wrong surround sound setup because they use duplicate which copies and keeps the same volume for all channels. This gets the job done but it is lazy although my lines are much better. Of course you need to tweak the lines a little bit to make it work for your sound card.
Well in stereo it's simulated but when i use a dvd it sounds like a 5.1 should. Any ways i'm happy. Very happy.
 
Old 08-13-2006, 06:40 AM   #12
Napalm Llama
Member
 
Registered: Nov 2004
Location: Bristol, UK
Distribution: Gentoo 2005.0
Posts: 224

Rep: Reputation: 30
Quote:
Originally Posted by Electro
The lines from the gentoo-wiki site provides wrong surround sound setup because they use duplicate which copies and keeps the same volume for all channels. This gets the job done but it is lazy although my lines are much better.
Ah, I see what you're doing now - I agree, that should be a lot better. Do you think there's any chance you could update the Wiki with your wisdom?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
5.1 Surround Sound, with On Board Sound Card computergee Linux - Hardware 7 02-25-2006 12:03 AM
Surround Sound? LegendBreath Linux - Hardware 1 06-06-2005 01:11 PM
Sound blaster Live! 24bit + Surround sound Jay_highlands Linux - Hardware 3 05-14-2005 01:37 AM
Surround Sound help gexzd Linux - Software 1 03-30-2004 11:34 PM
Sound Blaster Audigy Surround Sound GameboyHippo Linux - Hardware 0 12-04-2003 08:15 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 04:35 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration