fethica / FRadioPlayer

A simple radio player framework for iOS, macOS, tvOS.

Home Page:https://fethica.github.io/FRadioPlayer/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Airplay to an Apple TV prompts a black screen instead of a now playing notification

sbrighiu opened this issue · comments

Airplay-ing to an Apple TV device will prompt a black screen with a loader and a progress bar instead of running as a background music app -> TuneIn (which i do believe uses AVPlayer, but i cannot confirm), Soundcloud, Spotify ..

Reproduce:

  1. Open the app, setup FRadioPlayer, and call play()
  2. Wait until you hear the music, and then go into Control Center and Airplay to an Apple TV (not headphones.. it needs to be an Apple TV for this to be reproduce-able)
  3. Observe the now playing info is not visible anywhere and the screen goes fully black, with only a loader and a progress bar.

The annoying part is the fact that if you dismiss the screen, it does not continue playing the music and will most of the times corrupt the session on that Apple TV.

Did you set MPRemoteCommandCenter and MPNowPlayingInfoCenter in your app?

Yes, the now playing information is set up and works on the device, but not on the Apple TV.

Thanks for reporting the issue, I will do more testing on an actual Apple TV.

+1 on this issue

Debugging a little more, this only seems to happen when directly using Airplay to an Apple TV.

Using Airplay 2 you can select multiple devices to airplay to. If I select an Airport Express first, then select the Apple TV as a second Airplay output, the metadata will correctly show in the top right of the Apple TV screen (and also full screen album art + artist/track).

This seems related to the timedMetadata KVO, it always returns nil when directly Airplaying to an Apple TV.

@apeatling thanks for the informations!

Hey @apeatling , @sbrighiu

I added a fix to this issue in the latest release 0.1.16

Thank you!

Thanks for the feedback, closing the issue 👍