You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In my Flutter app the user is able to play a video, I use the chewie package for this. This player uses a VideoPlayerController (from the video_player package) to somewhat control the video player, which ultimately allows me to use the audio_service package to create an audio session. I use this to continue playing the video when the app is paused (in the background or when the phone is locked).
The problem I'm faced with now is that when I've started a video with background audio playback successfully, but then want to close that video, I can't seem to get the audio session to stop as well. This is especially visible on iOS (like in this screenshot), where the media player stays active even though I shut down the video and attempted to shut down the audio session as well.
Here's my audio handler, I basically close the audio handler by calling resetVideoFunctions. I have tried multiple things though, like closing/disposing the mediaItem, closing/disposing the player state, closing/disposing the streamController, closing/disposing the video controller, etc., etc... Nothing works
In my Flutter app the user is able to play a video, I use the
chewie
package for this. This player uses aVideoPlayerController
(from thevideo_player
package) to somewhat control the video player, which ultimately allows me to use theaudio_service
package to create an audio session. I use this to continue playing the video when the app is paused (in the background or when the phone is locked).The problem I'm faced with now is that when I've started a video with background audio playback successfully, but then want to close that video, I can't seem to get the audio session to stop as well. This is especially visible on iOS (like in this screenshot), where the media player stays active even though I shut down the video and attempted to shut down the audio session as well.
Here's my audio handler, I basically close the audio handler by calling
resetVideoFunctions
. I have tried multiple things though, like closing/disposing themediaItem
, closing/disposing the player state, closing/disposing thestreamController
, closing/disposing the video controller, etc., etc... Nothing worksHopefully someone can help me close the audio session!
The text was updated successfully, but these errors were encountered: