opentok / opentok-android-sdk-samples

Sample applications illustrating best practices using OpenTok Android SDK.
https://tokbox.com/developer/sdks/android/
MIT License
211 stars 169 forks source link

Android:- Audio shuts down when move the app to background state #506

Open tusharsharma718 opened 4 months ago

tusharsharma718 commented 4 months ago

Describe the bug When we put the app in background during the videocall the audio shuts down in background state

To Reproduce Steps to reproduce the behavior:

During the videocall keep the app into the background and you will find the audio shuts down and publisher and subscriber are not able to hear anything as the audio is completely disabled in background state.

Expected behavior The audio should be enabled in background state as in case of iOS the audio is enabled in the background state of the app.

Device (please compete the following information):

Additional context Incase of iOS enabling audio in background state can be achieves simply by adding the Background State: Audio capability to app Info.plist but in case of android there is no such thing that can help to enable audio in the background state.

v-kpheng commented 4 months ago

@tusharsharma718, there should be audio. Which sample app did you use to reproduce this?

tusharsharma718 commented 3 months ago

@tusharsharma718, there should be audio. Which sample app did you use to reproduce this?

@v-kpheng I am using the following sample app to reproduce it :-

Path of sample app:- opentok-android-sdk-samples/Basic-Video-Capturer-Camera-2-Java

tusharsharma718 commented 3 months ago

@tusharsharma718, there should be audio. Which sample app did you use to reproduce this?

@v-kpheng Any update on the issue?

v-kpheng commented 3 months ago

@tusharsharma718, apologies for the belated reply.

You should have audio. We'll investigate. That said, are you seeing the same issue with other sample apps as well? Also, which model phones did you use to reproduce?

v-kpheng commented 3 months ago

@tusharsharma718, we couldn't reproduce the issue, even when using https://github.com/opentok/opentok-android-sdk-samples/tree/main/Basic-Video-Capturer-Camera-2-Java. I think we might be missing a step. Any ideas?

v-kpheng commented 3 months ago

For context, we tried to reproduce using a Galaxy M51.

tusharsharma718 commented 3 months ago

@tusharsharma718, we couldn't reproduce the issue, even when using https://github.com/opentok/opentok-android-sdk-samples/tree/main/Basic-Video-Capturer-Camera-2-Java. I think we might be missing a step. Any ideas?

@v-kpheng ,apologies for late reply. Thanks for providing the input and I tried to test on other devices and it was working fine but it doesn't work on my android device . Given below is the configuration of my android device in which I am facing the issue :

OS and version: Android-12 Device- Samsung Galaxy S10

tusharsharma718 commented 2 months ago

@tusharsharma718, we couldn't reproduce the issue, even when using https://github.com/opentok/opentok-android-sdk-samples/tree/main/Basic-Video-Capturer-Camera-2-Java. I think we might be missing a step. Any ideas?

@v-kpheng ,apologies for late reply. Thanks for providing the input and I tried to test on other devices and it was working fine but it doesn't work on my android device . Given below is the configuration of my android device in which I am facing the issue :

OS and version: Android-12 Device- Samsung Galaxy S10

@v-kpheng Any update on this issue?

v-kpheng commented 2 months ago

@tusharsharma718, sorry for the belated reply. No one on the team has an S10. The closest(?) we have are S20 and S21. In any case, can you share some logs? Maybe it'll shed some light 🤞 Thanks!