• 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 /
  • Help Room /
avatar image
0
Question by dkstrong · Feb 08, 2019 at 10:52 PM · audioaudiosourceaudioclipaudiolisteneraudio clipping

What causes weird cracking/popping sound when playing 3d sound

I am having a problem where when I spawn a prefab with an AudioSource, the sound it makes is distorted/pops when it firsts starts playing. After a half second it plays as normal. The sound clip should just be a constant humming sound

Does anyone know how to set this up so I don't get this cracking sound? (I can't tell if this is distortion or an artifact of 3d sound or what). I've tries using different audio clips and I am still getting this problem.

Unity Version: Unity 2018.3.4f1

Video demonstrating the issue: https://streamable.com/gzus5

AudioSource Settings: alt text

capture.png (30.9 kB)
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

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by rh_galaxy · Feb 11, 2019 at 12:29 PM

Sounds like clipping is occurring. Maybe you unintentionally start more than one clip, so that they together get too loud. Or that it is too loud to begin with. Volume 0.082 speaks against that... Does this still happen if you move the missile start to be at where it was after 0.5 sec in the original setup... does it sound ok from the start then?

Comment
Add comment · Show 2 · 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 dkstrong · Feb 11, 2019 at 02:04 PM 0
Share

I've tried spawning it further ahead of the camera, and it still does it. It shouldn't be playing the sound twice because the audio source is on the missile, and there is only one missile being fired at a time (using Play(), not PlayOneShot())

I think it might be clipping too, e.g. unity's spatial audio system is boosting is volume for closeness. But there needs to be a way to set the max volume on it so it doesn't go over the clipping level.

Right now as a workaround I am fading in all of my spatial sounds for the first second of playing to avoid the clipping noise. It's ok for bullet engine noises and stuff but making the timing of the sound look delayed when used with explosions.

avatar image zereda-games · Feb 11, 2019 at 08:10 PM 0
Share

have you tried to instantiate the source first then add the clip to the source after its been created then making it play and not play on awake? maybe nute volume of source when no clip is active and restore it once a clip isPlaying. this could all be removed again, its to see if the clip or the source is the cause of the unwanted sound.

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.

Welcome to Unity Answers

The best place to ask and answer questions about development with Unity.

To help users navigate the site we have posted a site navigation guide.

If you are a new user to Unity Answers, check out our FAQ for more information.

Make sure to check out our Knowledge Base for commonly asked Unity questions.

If you are a moderator, see our Moderator Guidelines page.

We are making improvements to UA, see the list of changes.



Follow this Question

Answers Answers and Comments

196 People are following this question.

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

Related Questions

Trying to use derive pitch and db from realtime microphone input 0 Answers

Can't get an AudioSource to play on awake 2 Answers

How to stop current audio before another audio starts? 0 Answers

Trying to use derive pitch and db from realtime microphone input 0 Answers

How to play 5.1 surround sound with 6 WAV files in scene 2 Answers

  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges