Search Issue Tracker

By Design

Votes

0

Found in

2018.4

2020.1.0f1

2020.2

Issue ID

1266474

Regression

No

There's a pop sound when changing the High Pass Audio Filter's Cutoff Frequency from a lower to a higher value

Audio

-

How to reproduce:
1. Open user's attached "HPFTest" project
2. Open the "SampleScene" Scene
3. Enter the Play Mode
4. In the Hierarchy select the "Cube" GameObject
5. In the Inspector set the Audio High Pass Filter's Cutoff Frequency to 10
6. In the Inspector change the Audio High Pass Filter's Cutoff Frequency to 100

Expected result: No pop sound when changing the Cutoff Frequency
Actual result: There's a pop sound when changing the Cutoff Frequency

Reproducible with: 2018.4.26f1, 2019.4.8f1, 2020.1.2f1, 2020.2.0a20

Notes:
- This is only happening on the Audio High Pass Filter Component, it does not happen on the Audio Low Pass Filter Component
- Only happens when changing the Cutoff Frequency from a lower to a higher value

  1. Resolution Note:

    It is an expected pop you get from a drastic change of a filter's cutoff frequency. FMOD does not perform any interpolation of its parameters, so if you need a smoother change, you need to write a script that gradually interpolates the cutoff to the target value over a couple of frames. You will likely need some kind of logarithmic mapping on the interpolation, since you're interpolating frequency where changes in the lower end are perceived more than in the higher end, and also depending on frame rate the interpolation may need to be carried out over several frames.
    The only thing in FMOD that is being interpolated is in fact volume changes, but even those have a fixed interpolation range that may be too jumpy for quick changes. This is why in the audio mixer we could not use this but had to do per-sample interpolation to eliminate artefacts from sudden changes, which adds significant cost to the mixing. The same would apply if we were to add this to all parameters in FMOD, and for filters this is even more expensive, because recalculating internal filter coefficients is way more expensive, so it also needs a check then to only react on changed parameters and only recalculate the coefficients every Nth sample.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.