Prerequisites
- A Vega app created from a template. For instructions, see Build Your App.
- The W3C Media Player dependency, Babel configuration, and manifest permissions in place. For instructions, see Media Player Setup.
- A Fire TV device or emulator that you can deploy to.
Build the app
Confirm your dependency
Create the player screen
VideoPlayer instance that owns playback state, and a KeplerVideoView that renders the video surface.Render the screen from your app entry point
Replace the video URL
VIDEO_URL to a media file your device can reach. URL mode supports MP4, MP3, MKV, FLV, OGG, and FLAC. If you point it at an HLS (.m3u8) or DASH (.mpd) manifest, playback fails — those require MSE mode and a JavaScript player. See Selecting Playback Mode.Build, install, and run
Loaded to Playing.Add play and pause
TheVideoPlayer object exposes the standard HTMLMediaElement surface, so simple controls are a few lines. Wire this to a focusable button or a D-pad key handler:
currentTime, duration, and volume, and listen for timeupdate to drive a progress bar.
Troubleshooting
Next steps
- Selecting Playback Mode — choose between URL mode and MSE mode
- Shaka Player Integration — add adaptive streaming
- W3C Media integration with Vega Media Controls — connect to system playback controls

