Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
2
Question by baglyd · Sep 14, 2011 at 09:36 AM · audioaudiosourcestereo

Stereo sounds in 3D space

How can I make an audio source play in stereo, with 3D distance attenuation, but without 3D panning?

As soon as I use the 3D sound settings, Unity turns the audio clip into panned mono, instead of stereo. When I set the spread to 180, the panning is off, but it is still pure mono. (The audio clip setting Force to mono IS unchecked).

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

3 Replies

· Add your reply
  • Sort: 
avatar image
5
Best Answer

Answer by syclamoth · Sep 14, 2011 at 09:59 AM

Sounds play in stereo to give the illusion of depth to the sound- Just like we have two eyes to let us see how far away something is, we have two ears to hear how far off, and what angle, sounds are coming from. If you play a sound in 3d space, it does not make sense to play it stereo, because all of a sudden it is coming from exactly one point in space- the audio engine then converts the sound back into stereo when it gets sent to the speakers on your computer (so that it sounds like it comes from a point in space). If you want 3D distance attenuation, try just using the sound as a 2D sound, and manually changing the volume in a script which checks the distance to Camera.main.

Comment
Add comment · Show 4 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image baglyd · Sep 14, 2011 at 10:33 AM 1
Share

@syclamoth; Thank you for your answer! It makes perfect sense for sounds co$$anonymous$$g from a single point in space, but not all sounds do: Wind, water, rain, traffic, ambiences etc. originates from a direction, but not a single point. The audio engine i Unity doesn't convert the sounds back into stereo, as you say, but to mono in multiple speakers, which is something different. And that is my problem... But using the 2D sound method, and change the volume in a script might do it for me.

avatar image syclamoth · Sep 14, 2011 at 10:37 AM 1
Share

Another thing, if you want to simulate directional effects on it, you might consider applying a mild low-pass filter on the sound which attenuates depending on whether the listener is pointing towards the audio source- we get a surprising amount of directional information from the weird shape of our ears, which make sounds have different frequency signatures from different directions.

avatar image maurovanetti syclamoth · Apr 03, 2017 at 09:59 PM 0
Share

@syclamoth Have you got more technical information about the shape of the filter and its attenuation function relative to the angle of incidence of sound?

avatar image iitoash · Jun 28, 2020 at 07:42 AM 0
Share

or you can just force the sound clip to mono in the inspector settings

avatar image
0

Answer by BerggreenDK · Sep 14, 2011 at 09:51 AM

Not sure I understand the problem, but what if you have two mono sounds and place them manually? would that suit your needs?

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image
0

Answer by Jon_Olive · Jun 28, 2020 at 09:10 PM

The best solution to this is to treat your stereo sound as coming from 2 "virtual speakers" in 3d space. Unfortunately it's a pain in the arse in Unity since, as BerggreenDK says, you have to split the sound into two monos and have them come from 2 3d sources - one of the few times when Unreal's audio implementation wins over Unity since it supports stereo directly (you just specify the distance between the "speakers"). It really depends on the context of what you are trying to achieve what the spacing between the sources should be - but as a guide - if you want it to sound as it would coming from a pair of stereo speakers you want the subtended angle between speakers at the listening position to be about 60 degrees.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

8 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

What are the advantages of stereo sound effects? 0 Answers

4 Directional Audio 0 Answers

Playing audio in one ear or shifting the mix for the whole listener 0 Answers

There is no 'AudioSource' attached to the 4 Answers

Music Visualiser Troubles 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges