Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

video stops background music #175

Open
alexlnos opened this issue Oct 2, 2020 · 5 comments
Open

video stops background music #175

alexlnos opened this issue Oct 2, 2020 · 5 comments

Comments

@alexlnos
Copy link

alexlnos commented Oct 2, 2020

hello, tell me how to start the video so that the music is not paused
I have music playing on my phone (not in my application) and I want to open a page with a video, but so that the music doesn't stop, how can I do this?

@natebgurutech
Copy link

I am also wanting to do this. The documentation for Android says we need to manage our audio focus in some way. Here is some information I found about it:

Android:
https://developer.android.com/guide/topics/media-apps/audio-focus#java

iOS:
https://stackoverflow.com/questions/29024320/how-can-i-allow-background-music-to-continue-playing-while-my-app-still-plays-it

I'm not completely sure if this should be up to the developer to try to get something working or if this should be part of / documented for this library.

@ZmanElete
Copy link

Hey I'm having this issue too 👍

@natebgurutech
Copy link

natebgurutech commented Dec 11, 2020

After a little googling, it looks like a different library, Nativescript Exoplayer, does allow background sound.

I know that isn't a fix for this library but it does let us know that this plugin should probably take care of it for us. I don't know if exoplayer is NativeScript 7 ready.

Here's a small excerpt of their readme:

backgroundAudio - (boolean) - optional
If set to true, the audio for the video won't pause any existing audio playing. Instead it will play simultaneously with the existing audio. This is similar to how instagram and facebook play their video audio.

https://github.com/NathanaelA/nativescript-exoplayer/tree/master/src#properties

@natebgurutech
Copy link

Is there a possibility of getting these little options into this library? It would really help if we could allow sound to play in the background of our videos.

@ZmanElete
Copy link

Agreed. Still interested in these changes. Any updates?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants