Looking into smoothed value for some parameter interpolation, but it doesn’t seem like on first glance SmoothedValue is thread safe.
It seems like looking at the code that it would be totally possible for setTargetValue and getNextValue to be called at the same time from different threads.
This would create a race condition on updating the step member variable, which is updated in setTargetValue, and used in getNextValue.
I don’t see any atomics, or any locking to synchronize things. I want to be able to safely call setTargetValue from a UI thread, and getNextValue from the audio thread.
Am I missing something obvious?
Thanks for the help!