I am using linephone library to call trough app. I have integrated everything using the example code given here
My issue is Case 1 - if i call on some number and if it plays some sound like- number is not available right now and so on.... (EarlyMedia case) and disconnected.
Case2 - Now if i call on proper working number. Other phone get phone call and if other phone receives the call then some music tone will play. Actual sound will not come on both the side.( EarlyMedia-> Connected- > StreamsRunning->paused) this callback flow is calling.
Note: Both case need to execute one by one. If app kills and restart then everything work fine.
Case 1 Callback flow (OutgoingInit->OutgoingProgress->OutgoingEarlyMedia->End)
Case 2 Callback flow (OutgoingInit->OutgoingProgress->OutgoingEarlyMedia->Connected->StreamsRunning->Pausing->Paused)
Please help me out for How to avoid the call going to paused state after connecting?
I am using org.linphone:linphone-sdk-android:5.1.36 for android.
Thanks in advance
UPDATE: LOGS
Your call is paused because your app has lost (temporarily) the audio focus. That is the recommended behavior by google for such scenario, see https://developer.android.com/guide/topics/media-apps/audio-focus for more information about it.
If you don't want linphone-sdk to automatically pause calls when audio focus is lost, you can use the following configuration item:
Alternatively you can ask the SDK not to make any audio focus request if you prefer to handle it yourself in your app:
There is a wiki entry about audio focus for Android in linphone-sdk here: https://wiki.linphone.org/xwiki/wiki/public/view/Lib/Getting%20started/Android/#HAudiofocus