Crackling/Distorted Audio in Exported Video

I just repeated a sine.WAV test using your project. I generated a stereo 48 Khz Sine.wav using Audacity, opened your project in Shotcut, replaced the clip on the timeline with my Sine.wav, exported using the YouTube preset with parallel processing and hardware encoder turned off, opened the newly exported test.mp4 in Audacity. The sound is funny with a chorus-like (?) effect, and the wavform looks much different compared to the original (on top):

If I export to WAV, it does not do that; it is just like the original. I zoomed in further to see the curvature of the wave, and visually inspected all 30 seconds by paging down and found no artifacts in the form of breaks in the curves.
Next, I tried YouTube preset again but with a different audio codec - ac3 -in MP4. It does not exhibit this effect, and neither do I see any visual breaks in the waveform. I suspect this may be this is a side effect of the sort of lossy compression in the AAC encoder. So, I exported with MP3 preset, and it does not do it either. Maybe this is how AAC is bad or just this FFmpeg AAC encoder or this FFmeg version. Next, I opened the MP4 with ac3 in Handbrake, and tested its MP4 with AAC output, and it is very similar to Shotcut. I do not think this is the same problem you are reporting, but it seems the AAC codec is problematic in this manner of test.

1 Like