Release media player resources when app goes to background.
Apps must release unused media resources, specifically media playback related resources, when they are pushed to background by the Lifecycle Manager (LCM). The general guidance here is that for VOD content playback, the app must release the media resources and go back to the Movie or Content detail page. To allow users to quickly resume their playback experience from where they left off when the app is brought back to foreground, the app should retain the context of the live and VOD content playback. Apps can release media resources by deinitializingVideoPlayer or unmounting the Video component from the render tree.
Codec selection
- Audio device capability based codec selection. The app must select the appropriate audio codec (AAC or Dolby) for playback depending on the audio capability of the connected HDMI display device such as a TV or AVR
- Switching between Bluetooth headset and HDMI output. During playback, the user might switch between Bluetooth headset and HDMI output. This can lead to changes in the supported audio codec on the display device. For example, HDMI output supports Dolby, whereas a Bluetooth headset doesn’t. Apps are required to detect this change in audio output capability and trigger audio codec switch in the MSE player.
Enforce Sequence Mode
A general recommendation is that you use the sequence mode for HLS and MPEG2TS streaming content. If you need to play MPEGTS content in HLS adaptive streams, enable the sequence mode flag as shown in the following sample code.Manifest requirements
To properly support media playback, you must have the following entries in your manifest.toml file.- com.amazon.audio.stream - for all Playback/Record clients
- com.amazon.audio.control - for all AudioManager API clients
- com.amazon.audio.system - for all AudioManager API clients
Limitation of Secure Video Decoder sessions
The first Fire TV based on Vega OS supports only one secure video decoder instance. To perform back to back secure video playback, you must deinitialize the firstvideoPlayer instance before initializing the second one.
If you don’t deinitialize first videoPlayer instance, the second playback will fail.
The following code sample shows how to deinitialize a videoPlayer instance and start a new one.

