1

Is it possible to cast a new media while the app is running in the background? (Like loading the next track when playing a playlist)

My understanding is that on iOS, the GCKCastSocket is closed when the app is in background (even when running in background mode). Is there a way around that behaviour? Keeping the socket open would also allow for real time updates of the lock screen controls as described in the design checklist.

1 Answers1

0

where is your media hosted? If it is in the cloud, you can send the "playlist" to the receiver and write a simple custom receiver to go to the next track when one completes.

Ali Naddaf
  • 16,951
  • 2
  • 21
  • 28
  • Thanks. As the media is indeed hosted in the cloud, using a custom receiver would work. However, this doesn't solve the problem of the lock screen and notification controls. How can I keep them synced with what's playing on the chromecast if the media has changed? – Nicolas Chourrout Mar 18 '14 at 22:38
  • Are you still referring to iOS? On iOS, there is very little you can do there. – Ali Naddaf Mar 18 '14 at 22:49
  • Yes it's regarding iOS. I know the lock screen implementation is optional but you're saying it's also not feasible? – Nicolas Chourrout Mar 19 '14 at 08:42
  • 1
    I am not familiar with iOS so whatever I say about iOS development should be considered a guess at best. As far as I know, there is not "clean" way to have the lock screen controller for a Cast app since it really doesn't play a local media, hence apple may reject that at any moment. I have also heard that some play an empty audio file to fake that but again that is not clean, nor right. Our current iOS sdk breaks the connection socket when the app goes into background for these reasons (and recover connection when app comes to foreground) as a result, lock screen won't be doable currently. – Ali Naddaf Mar 19 '14 at 14:32