Code Block player = new Player(); player.playlist = new Playlist(); audio = new MediaItem('audio', stream); audio.title = title; audio.artworkImageURL = artwork; audio.subtitle = subtitle; audio.description = description; player.playlist.push(audio); player.play();
How can i make the image and subtitle appear again with tvOS 14.0.1 and 14.2?
The same thing happens when playing audio with this sample project:
https://developer.apple.com/documentation/tvmljs/playing_media_in_a_client-server_app
It looks like tvOS 14.0.1+ changed the default value for supportsPictureInPicturePlayback from false to true. The docs say default is false until now https://developer.apple.com/documentation/tvmlkit/tvapplicationcontrollercontext/3192087-supportspictureinpictureplayback… When tvOS 14 added Picture-in-Picture Support (PIP), we made the default value for this value is ‘true'. This has broken the existing behavior for audio.
To get around your issue, you need to explicitly set the property ‘supportsPictureInPicturePlayback’ (linked below), to false, on your app’s TVApplicationControllerContext.
<https://developer.apple.com/documentation/tvmlkit/tvapplicationcontrollercontext/3192087-supportspictureinpictureplayback>
let appControllerContext = TVApplicationControllerContext()
appControllerContext.supportsPictureInPicturePlayback = false
Setting this will make the Now Playing UI appear again. …