/// <summary> /// Enables or disables the default stream attenuation experience (auto-ducking) provided by the system. /// </summary> /// <param name="optOut">True to disable system auto-ducking, or false to enable.</param> public void SetDuckingPreference(bool optOut) { Marshal.ThrowExceptionForHR(_audioSessionControl2.SetDuckingPreference(optOut)); }