Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

I've trying to bring in surround sound audio into my project. I've set my computer up to run in 5.1 and when I play a 6 channel audio through windows media player (it's a test audio that does left speaker, right speaker etc) it works fine.

However, when I run it through Unity, all I get is the front 3 channels. I've set it in the Edit -> project settings -> audio to be 5.1 in there. I even set it in code with following:

void Start() { AudioSettings.speakerMode = AudioSpeakerMode.Mode5point1; } How ever, when I run a debug line of:

print ( AudioSettings.driverCaps); It tells me that Unity is only playing in stereo. Is there something I'm still not doing?

I should also add I've ran 10 different tests using the 3D audio pan and spread options. I've set both to either being fully off, half way on and full. Still the same results.

share|improve this question

1 Answer 1

Taking a quick look at the AudioSettings reference, it says that AudioSettings.driverCaps gives the speaker mode capability of the current audio driver. If the current audio driver is only capable of stereo playback, then that's why you aren't hearing 5.1. Try debug printing the value of AudioSettings.speakerMode to see what's actually set. The speakerMode reference says: "If a speaker mode is set beyond the drivers capability, the audio behaviour is undefined."

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.