Page 1 of 1

VLCKit for iOS stops playing when app is in background

Posted: 30 Dec 2014 14:18
by norel
Hi all,


I try to make VLC to continue playing when my application is in the background but it doesn't work.

I already use AVPlayer and it works fine, but not with VLC.

My info.plist is already configured with the "UIBackgroundModes" value containing "audio", and my code is also using AVAudioSessions :

Code: Select all

[[AVAudioSession sharedInstance] setCategory:AVAudioSessionCategoryPlayAndRecord error:nil]; [[AVAudioSession sharedInstance] setActive:YES error:nil];
I even tried to include the whole player view controller from the VLC iOS application source code but the playback is still stopped when the application is no longer opened.
edit = the view controller from the vlc application actually works as intended. However, my own code doesn't play in the background when I try to implement VLC manually in my own view controller, same for the sample projects (dropin-player etc.)

Do you have any idea of something I miss?

I am using the latest git version of MobileVlcKit, on the iPhone simulator.

Thanks!

Re: VLCKit for iOS stops playing when app is in background

Posted: 06 Jan 2015 15:40
by norel
Actually the simulator on iOS7 doesn't handle background playing very well. (thanks Apple!)

I used a MobileVLCKit build for iOS devices and it worked perfectly on iPhones/iPad.

Closed thread :)

Re: VLCKit for iOS stops playing when app is in background

Posted: 06 Jan 2015 16:29
by Jean-Baptiste Kempf
Interesting to know.