2

I can use ringtones built into my app for incoming calls with CallKit by calling

let configuration = CXProviderConfiguration(localizedname:"MyApp")
configuration.ringtoneSound = "mysound.wav"

However, I want to use system ringtones, like the "Beacon" ringtone which is stored at "/Library/Ringtones/Beacon.m4r". Setting configuration.ringtoneSound to "/Library/Ringtones/Beacon.m4r", "Ringtones/Beacon.m4r", "Beacon.m4r" all don't work.

Does anyone know if it is possible to use the system ringtones, and how to use them?

To repeat: The problem is not playing the ringtones, that's easy. The problem is making CallKit use the system ringtones for an incoming call.

gnasher729
  • 51,477
  • 5
  • 75
  • 98
  • 1
    Does this answer your question? [Playing system sound without importing your own](https://stackoverflow.com/questions/7831671/playing-system-sound-without-importing-your-own) – dandan78 Jan 16 '20 at 10:17
  • 2
    No. I have code that plays system ringtones. What I don't have is code that plays system ringtones through CallKit, when a VoIP call comes in and I have to show the CallKit user interface. – gnasher729 Jan 17 '20 at 00:01
  • @gnasher729 Did you find any solution yet? If you did please share so that we can get the right solution. Thank you – Md. Yamin Mollah May 15 '22 at 21:56

0 Answers0