- Home /
Surround Quad - Unity with four speakers
I'm having troubles with the "Surround Quad" option in Unity 3.4.2.
I have a MacBook Pro connected to an external firewire sound interface which in turn connects to four speakers. In spite of having 4 outputs, my sound card's only receiving 3 signals from Unity. Front left and front right are ok, but that's it.
In a small scene with an audio listener in the center of the screen and a mouse-controlled audio source, channel 1 lights up when the source is on the left, channel 2 when it is on the right, channel 3 isn't active whatsoever, and channel 4 lights up in almost all situations, leading me to believe it is incorrectly mapped to the center channel.
I've configured the speaker setup with "Audio MIDI Setup" and confirmed all speakers are working. When tested with 5.1 audio from a movie it also worked without problems.
Is it a channel mapping issue? And if so, is it possible to re-map Unity's audio channels?
Thanks in advance for any help.
Edit: I'm now using Soundflower for my tests. Using "Audio MIDI Setup" and "Audacity" I confirmed all the six channels are producing sound (i.e. the horrible noise "Audio MIDI Setup" uses as test sound). My scene consists only of an audio listener in the center and an audio source circling around it, but recording the sound outputs in Audacity still shows weird results.
If needed, my test scene can be found here.
Again, thanks in advance for any help provided.
While unfortunate, it's nice to see I'm not the only one having this problem. I've included extra information. Hopefully it will be of some use to someone.
@BY0LOG1C "unfair and deceitful" - the amount of software products I've used that proclaim to support audio features that do not function when tested and clearly have had no quality control applied to the them is the reason I have used such harsh words. This is a product that people pay for and as such it should work as advertised.
Answer by briancullen13 · Feb 03, 2012 at 08:23 PM
I've got 5.1 working on the MAC with and MBOX pro and with an MAudio 410. Strangely enough I have to set the audio in Unity to 7.1. 5.1 gives messy results. The 7.1 setting for use with a 5.1 speaker setup uses the centre speaker for panning between the frontal left and right speakers, so you will get a noticeable dip without one. The Listener position is also the wrong way around if spread is set to 360 degrees (weird) so I set it to zero. Unfortunately, Quad still seems to give totally weird results. Good luck- b
ps try using the simple UnityScript snippet below to see how Unity is reading your audio card.
function Awake ()
{
AudioSettings.speakerMode = AudioSettings.driverCaps;
print (AudioSettings.driverCaps);
print (AudioSettings.outputSampleRate);
}
Yup, that did it. Setting Unity to "Surround 7.1" and the "Audio $$anonymous$$IDI Setup" to "5.1 Surround" yields perfect 5.1 surround. Freaky.
About the code snippet: when I used it Unity printed out the correct sound settings, i.e. if in "Audio $$anonymous$$IDI Setup" I set "5.1 Surround", it would output "$$anonymous$$ode5point1". The same with sample rate, it was also correctly displayed ("48000").
Since my sound setup seems ok and is correctly detected, I guess there's some Unity internal problem with the channel mapping. But it seems odd that such a weird channel mix-up made it into version 3.4.
Well, but anyway you've solved my problem, so I'm good. Thank you very much for your help!
Glad to be of help. I'm going to check out the beta too as I'm having issues with AudioLowPassFilter.cutoffFrequency conflicting with the low pass filter curve in the inspector. See issue below. I'll let you know if the audiomode settings have been fix for the beta soon.
Answer by rolandcahen · May 18, 2012 at 09:23 AM
I've been trying to connect Unity multichannel audio output to my Digidesign digi 003 on 8 channels. I could not do it through CoreAudio nor Digidesign core audio, neither using soundflower directly. The only way i could do it was to create a Max/MSP bridge patch with Soundflower multichannel as an input and my digi core audio driver as an output. This means as well that Soundflower (16ch) is selected in the Audio MIDI Setup.
Answer by rolandcahen · May 19, 2012 at 10:37 AM
Today, God knows why, a firewire icon appeared in Audio Devices window in front of "Digidesign HW( 003)", and I could connect the multichannel without going through Soundflower + Max MSP.
I have tested all combinations, changing the "Audio Project Seetings" in Unity 3.5 and the "Audio Devices" of MacOs 10.6.8. My conclusion is that Unity only outputs 5+1 channels, whatever the audio project settings might be.
The channels used seem to be random or bugged. They depend on the speaker config which does not make sens. In addition, the "Audio Project Seetings" default speaker mode changes when you press play and stop. What does it mean ?
The result is also different when using Soundflower where channel 1 is never used.
Is there a double check loop between CoreAudio and Unity ? Odd isn't it ?
Let's see what tomorrow brings, but at the moment the hole thing is not very safe.
RC
Answer by briancullen13 · May 19, 2012 at 01:29 PM
Did you read this info in the answer above? "The 7.1 setting for use with a 5.1 speaker setup uses the centre speaker for panning between the frontal left and right speakers, so you will get a noticeable dip without one. The Listener position is also the wrong way around if spread is set to 360 degrees (weird) so I set it to zero. Unfortunately, Quad still seems to give totally weird results." - b
Answer by rolandcahen · May 19, 2012 at 03:37 PM
Hello Brian, I don't get the point you make about the 7.1 setting for use with a 5.1 speaker setup. I did have noticed several holes in different configs, inversions and voice lacks. I have been trying not only quad but all configs changing both in unity and core audio setup. My speaker device is 8 + 1 and should allow all configs to work (with little rotation shifts). Of course the central speaker is part of 5.1 and 7.1 setup. I have not notice differences changing the spread yet, but I will try systematic testing on that point. The hole things does not look properly debugged or just unclear.