I am writing a basic Swift audio streaming application using AVPlayer
and wanted to know if it was possible to change the default display text of the AVPlayerViewController
. Currently the AVPlayerViewController looks like the following when I connect to the stream successfully:
When the application is connected to the stream I am able to pull metadata using an observer on AVPlayerItem.timedMetadata
. I want to know if I can override the default "Live Broadcast" text with a string, such as the metadata I am pulling. I know I could create a subview with a label and have the text displayed using contentOverlayView?.addSubview
, but I think it would be cleaner if I could display the text directly in the AVPlayerViewController
above the pause button.