RealityView with FairPlay

I'm trying to implement the playback of an HLS content with FairPlay, and I want to insert it into a RealityView using a VideoMaterial of a sphere.

When I use unencrypted HLS content everything works correctly, but when I use FairPlay it doesn't.

To initialize FairPlay I am using the following in the view:

let contentKeyDelegate = ContentKeySessionDelegate(licenseURL: licenseURL, certificateURL: certificateURL)
                // Create the Content Key Session using the FairPlay Streaming key system.
                let contentKeySession = AVContentKeySession(keySystem: .fairPlayStreaming)
                contentKeySession.setDelegate(contentKeyDelegate, queue: DispatchQueue.main)
                contentKeySession.addContentKeyRecipient(asset)

Has anyone else encountered this problem?

Note: I'm testing in Vision Pro directly because the simulator hasn't support for FairPlay.

Replies

Hello @AlvaroVG,

VideoMaterial supports FairPlay Streaming. Can you confirm that your FairPlay stream works in AVPlayerViewController?

Yes, with AVPlayerViewController without VideoMaterial works. Can you provide a simple example of how to initialize AVContentKeySession using VideoMaterial? Thanks!