x


audio is distorted at speed

i have a car, wiith a horn, and this script:

function Update () {
  if (Input.GetKey(KeyCode.H)) {
    if(!audio.isPlaying) {
      audio.loop = true;
      audio.Play();
    }
  } else {
    audio.Stop();
  }
}

but when i drive at high speeds, the sound becomes very distorted. How can i fix this?

more ▼

asked Aug 08 '10 at 08:10 PM

Fishman92 gravatar image

Fishman92
2.4k 101 113 128

(comments are locked)
10|3000 characters needed characters left

1 answer: sort voted first

Edit->ProjectSettings->Physics(or was it Audio?)->DopplerFactor

However, that parameter is global, so it will affect all your sounds and all your scenes. If you make sure your models are in meters (e.g., the car should be around 3-5 worldcoords long), the doppler effect should be realistic.

If that does not help you, we'd need some more info about your problem: What kind of distortion? Does the sound change pitch? Is it too loud? Is it choppy? Does your car have a driving sound and does that have the same problem? etc.

more ▼

answered Aug 08 '10 at 09:01 PM

Wolfram gravatar image

Wolfram
9k 8 20 52

the sound gets distorted in pitch, but very fst, like computerized sounds, almost a wobble in the audio. THe driving sound does the same thing but it is a lot less noticeable.

Aug 08 '10 at 09:38 PM Fishman92

Have you tried changing the DopplerEffect? Is your camera moving relative to your car? What's the scale of your car?

Aug 08 '10 at 09:45 PM Wolfram

i haven't tried the doppler effect. The camera moves relative to the car, and the car is to scale with unity (1 unit = 1 meter)

Aug 09 '10 at 11:57 AM Fishman92
(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

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

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x1029
x525
x357

asked: Aug 08 '10 at 08:10 PM

Seen: 1172 times

Last Updated: Aug 08 '10 at 08:10 PM