Detect Apple TV 4K playback capability

We have an uhd.m3u8 for playing Dolby Vision on Apple TV 4k, and another hd.m3u8 for regular 1080p playback. How can we determine the user's device and TV are capable for playing 4K HDR? Does tvOS SDK provide an API to tell developers this device with the TV can play 4K HDR?


Thank you for response!

Accepted Reply

The correct and recommended path here is to provide a single, blended playlist that includes variants to support both SDR and HDR playback. AVFoundation will automatically select the most appropriate variant for the device. We would not recommend trying to deliver specific playlists per device.

Replies

I'm trying to find the same answer. From my research, I found out that the only thing we can count on is UIScreen.main.nativeBounds to know if Apple TV is 4K or not. Did you find extra APIs we can use for it?

The correct and recommended path here is to provide a single, blended playlist that includes variants to support both SDR and HDR playback. AVFoundation will automatically select the most appropriate variant for the device. We would not recommend trying to deliver specific playlists per device.

A blended playlist including HDR and SDR streams is what we will use.


But I think the question still stands.


How can we determine the user's device and TV are capable for playing HDR?


We'd like to show onscreen indicators "showing off" HDR or offering upsell opportunities or tailoring HELP specific to a customer.


AVPlayer.availableHDRModes only tells us about the Apple TV device, and not whether the device is capable with the current TV.


is there any way to get this?

Hi Antony,


That API only includes the modes that both the Apple TV and the attached display can support. For example, if the external display does not support HDR10, then that wouldn't be included in the returned list.


Thanks,

Josh

Hi Josh


Thanks very much for getting back to me, but that doesn't seem to be the case.


I have my Apple TV 4K attached to an old Samsung HD Ready TV from 2010, and if I simply run

print("HDR: \(AVPlayer.availableHDRModes))


on app startup, it outputs

(rawValue: 2)


Which is - AVPlayer.HDRMode.hdr10 - which the TV certainly will not support


How sure are you that it should work as you described, and give you the available mode of the TV and Apple TV combined? And can you explain why it doesn't dseem to be doing that for me?


Thanks again


Antony

It would be expected that value woudn't be returned if the TV doesn't actually support it, but I haven't tested with that specific TV.


Please file a bug report at bugreporter.apple.com with TV model details and the behavior you are seeing. Thanks!