Search Unity

Audio WebGL Audio Click Issue

Discussion in 'Audio & Video' started by qkjosh, Mar 17, 2020.

  1. qkjosh

    qkjosh

    Joined:
    Nov 29, 2015
    Posts:
    33
    I'm wondering if anyone has any insight into why this audio file would have a harsh scratch/pop sound at the end. This only affects the WebGL build, not Desktop. It occurs in multiple versions of Unity, though I created a build in Unity 2019.3.1f1 to demonstrate. The audio file, if you check the waveform, begins and ends with silence (0db) so it's not that. Also, if I either shave off a small amount of the waveform's end or add a small amount of silence to the end, the click goes away. Since I can't isolate the *why* I'm paranoid that the clicking might be browser dependent and I'll have no way of knowing. Any insight is appreciated!

    Edit: I also tested to see if there is some minimum length for audio clips, but an even shorter version of this same sound had no clicking issue.

    Test build is here: https://sparrowhousegames.itch.io/dgmmmf57pcbua8
    Press space bar to fire the sound - extremely basic setup with a single audio source + clip.
    Audio file (44100 Hz, Mono) download is also available for download on that page.
     
    Last edited: Mar 17, 2020
  2. donjuanjavier

    donjuanjavier

    Joined:
    Nov 7, 2020
    Posts:
    3
    Just experienced the same issue - adding silence to the end of the track fixed the issue for me as well. Very strange...