I have an app that plays audio files. When the user starts audio playback, I want the audio to fade in from effectively 0 volume to 1 over a duration of 300ms or something like that.
I've been playing with the AudioGraph sample from GitHub and I learned that there's a Limiter effect that can control the loudness of an audio. How can I use this to change the loudness of an audio file over a duration of 300ms?
Or is there another way I can implement a fade effect?
You can use a timer to control the loudness when starting audio playback. This is a test I conducted in the official sample(Scenario5_InboxEffects.xaml.cs), and the effect is very good. The code is as follows.
Sorry, there is currently no related API in Windows Runtime AudioGraph.