LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 03-29-2008, 12:00 AM   #1
cdhgee
Member
 
Registered: Oct 2003
Location: St Paul, MN
Distribution: Fedora 8, Fedora 9
Posts: 513

Rep: Reputation: 30
Surround sound problems through IEC958 (S/PDIF) optical out


I have an interesting problem. I have my PC hooked up to my surround sound (7.1) system via an optical cable.

If I play a DVD in mplayer with hardware AC3 passthrough turned on, I get full surround sound through the speakers. This bit is fine.

Any other sounds played through the system come through the front speakers only. I've verified this by trying

Code:
speaker-test -c 8 -t wav
Sound only comes out for the Front Left and Front Right channels, even though the rest of the channels are printed. I've also tried testing it with 6 channels instead of 8 to no avail.

I think the problem might be that the optical GIGABYTEoutput is only encoding the front channels' signals, and not the surround channels, but there's no way to change this in the volume control. There is a channel mode, which has two options, "6ch" or "8ch". Changing it seems to have no effect.

Any ideas, anyone?

This is an onboard soundcard on a Gigabyte GA-P35-DS3L motherboard. The sound card is an Intel ICH9 with a Realtek ALC888 chip. It uses the snd-hda-intel kernel module.

Thanks in advance.
David

Last edited by cdhgee; 03-29-2008 at 12:01 AM.
 
Old 03-29-2008, 12:08 AM   #2
carl0ski
Member
 
Registered: Sep 2004
Location: Melbourne, Victoria Australia
Distribution: Support those that support you :)
Posts: 872
Blog Entries: 12

Rep: Reputation: 30
Quote:
Originally Posted by cdhgee View Post
I have an interesting problem. I have my PC hooked up to my surround sound (7.1) system via an optical cable.

If I play a DVD in mplayer with hardware AC3 passthrough turned on, I get full surround sound through the speakers. This bit is fine.

Any other sounds played through the system come through the front speakers only. I've verified this by trying

Code:
speaker-test -c 8 -t wav
Sound only comes out for the Front Left and Front Right channels, even though the rest of the channels are printed. I've also tried testing it with 6 channels instead of 8 to no avail.

I think the problem might be that the optical GIGABYTEoutput is only encoding the front channels' signals, and not the surround channels, but there's no way to change this in the volume control. There is a channel mode, which has two options, "6ch" or "8ch". Changing it seems to have no effect.

Any ideas, anyone?

This is an onboard soundcard on a Gigabyte GA-P35-DS3L motherboard. The sound card is an Intel ICH9 with a Realtek ALC888 chip. It uses the snd-hda-intel kernel module.

Thanks in advance.
David

This is normal behaviour since all other sound only provide stereo (2 channel sound)

Optical has 6 or 8 raw channels. when you play mp3 or stereo wave 2 speakers will sound the remainder receive blank sounds.

My Optical Recevier supports Stereo mirroring (redirects stereo to all speakers)

There are Alsa software ways to use alsa.conf file to repeat stereo sounds on the rear and side speakers also. however i could NOT get that to work with Optical/SPdif

Only with the analogue output.

Last edited by carl0ski; 03-29-2008 at 04:03 AM.
 
Old 03-29-2008, 12:11 AM   #3
cdhgee
Member
 
Registered: Oct 2003
Location: St Paul, MN
Distribution: Fedora 8, Fedora 9
Posts: 513

Original Poster
Rep: Reputation: 30
I agree with you in part - if I play an MP3, I'd expect only the front channels as it's only a stereo source.

Surely though if I'm using speaker-test and explicitly telling it to use 6 or 8 channels (to direct sound to individual channels at a time), then that should work?

Code:
[david@mars ~]$ speaker-test -c 8 -t wav

speaker-test 1.0.15

Playback device is default
Stream parameters are 48000Hz, S16_LE, 8 channels
WAV file(s)
Rate set to 48000Hz (requested 48000Hz)
Buffer size range from 64 to 16384
Period size range from 32 to 8192
Using max buffer size 16384
Periods = 4
was set period_size = 4096
was set buffer_size = 16384
 0 - Front Left
 4 - Center
 1 - Front Right
 7 - Side Right
 3 - Rear Right
 2 - Rear Left
 6 - Side Left
 5 - LFE
Time per period = 11.093216
 
Old 03-29-2008, 04:00 AM   #4
carl0ski
Member
 
Registered: Sep 2004
Location: Melbourne, Victoria Australia
Distribution: Support those that support you :)
Posts: 872
Blog Entries: 12

Rep: Reputation: 30
Quote:
Originally Posted by cdhgee View Post
I agree with you in part - if I play an MP3, I'd expect only the front channels as it's only a stereo source.

Surely though if I'm using speaker-test and explicitly telling it to use 6 or 8 channels (to direct sound to individual channels at a time), then that should work?
It doesn't work like that

I'm very confident you will find that Optical/SPDif is Always stereo only with exception of digitally packaged AC3 or DTS placed into Pass through mode (pass through forces receiver to decode it)
If you play a 5.1 DVD in mplayer or kaffeine without pass through it will be stereo even if you set 5.1.

If you hook up all 8 channels using analogue you'll find speaker test works.

In theory the only way to get 5.1 to SPDIF for all sound would be to direct all your sound to a Sound recorder (mencoder)
encode it to 5.1/7.1 in realtime using AC3 codec. then play back in realtime.


My Soundblaster Audigy and on board realtek HD have the same limitation in Windows XP also, it doesnt allow me to send multiple channels through SDPIF.

Soundblasters have a feature that allows 5.1 independant WAV channels over SPDIF (non standard) provided you use propietory Creative digital 5.1 speakers (hell with that)
 
Old 03-29-2008, 04:32 PM   #5
cdhgee
Member
 
Registered: Oct 2003
Location: St Paul, MN
Distribution: Fedora 8, Fedora 9
Posts: 513

Original Poster
Rep: Reputation: 30
I think I'm beginning to see what you mean. I ended up using the a52 alsa encoder to do realtime encoding to AC3, and setting this as the default output. If I use this with speaker-test, I can get output through 5.1 connected via the optical. I don't get the additional 2 channels if I try 7.1, but I'd guess that's because Dolby Digital was around before 7.1, so it's maybe not supported. But 5.1 is good enough for me, and my receiver can upmix that to 7.1.

Thanks for your help.
 
  


Reply



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
No sound output for my program (IEC958) eantoranz Linux - Hardware 1 10-19-2007 02:07 PM
nForce 430 / ASUS M2NPV-VM (surround) sound problems TrevorBradley Linux - Hardware 1 02-22-2007 04:39 PM
surround sound + microsoft wireless mouse problems garantatus Linux - Newbie 1 07-17-2006 07:19 AM
Suse 9.1 + nForce2 +S/PDIF output = No sound. Jeriko Linux - Newbie 2 11-03-2004 07:34 AM
Getting S/PDIF (digital optical) out to work? sancho Linux - Hardware 0 12-20-2003 09:46 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 06:03 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
Open Source Consulting | Domain Registration