question

fmapps avatar image
fmapps asked

Code samples for functioning video player app?

Does anyone know of any code samples available of a functioning video player app? (The Amazon-supplied sample is not functional.) Specifically, I'm looking for how to implement the capture of audio focus and media button input. I'm actually using Google's Leanback code because they were nice enough to provide something that does work, but it doesn't have that functionality because it's not necessary in Android TV (as far as I can tell). I have looked at the links that Amazon has in the FAQ that point to a couple things on Google site, and was able to figure out the audio focus enough to make it work, but I haven't been able to take control of the media buttons from another app, so when I try to pause a video, it actually turns the music from a previous app back on.
fire tv
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

DougM@Amazon avatar image
DougM@Amazon answered
Hello fmapps, We have documentation as to how to maintain audio focus at: https://developer.amazon.com/public/solutions/devices/fire-tv/docs/managing-audio-focus and we have documentation as to how to use the buttons available for the FireTV Remote: https://developer.amazon.com/public/solutions/devices/fire-tv/docs/amazon-fire-tv-remote-input And the FireTV Gamepad: https://developer.amazon.com/public/solutions/devices/fire-tv/docs/amazon-fire-game-controller-input Please let us know if you have any additional questions.
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.