2

This is a short question:

I'm using "YouTube Data API", and I've noticed that if the YouTube app isn't installed, all demos of the sample just show a dialog telling the user to install the app.

I'd like to have a different fallback, so that the video will still play.

I assume I can use WebView, but is there a better way? Maybe a VideoView ?

What's the best alternative, without any libraries (using just the framework) for when YouTube app isn't installed?

android developer
  • 114,585
  • 152
  • 739
  • 1,270
  • You should be able to play the video from the rtsp link you get from the API. – Nanoc Dec 02 '15 at 10:41
  • @Nanoc How? Using which API ? – android developer Dec 02 '15 at 10:49
  • With a VideoView and the Youtube API you are using... – Nanoc Dec 02 '15 at 10:53
  • @Nanoc As far as I know, VideoView doesn't support YouTube Urls. They are not direct links to video files. They have HTML content. About rtsp link, how do you get it? – android developer Dec 02 '15 at 10:55
  • Yeah, thats why i said rtsp link, you should take a look at the doc. maybe this helps: http://stackoverflow.com/questions/31606019/android-java-youtube-api-v3-0-get-video-rtsp-link – Nanoc Dec 02 '15 at 11:00
  • @Nanoc So it's not a part of the API... I thought I've missed something there (which can be easily true, as today is the first time I check the website). Do you know of a sample of how to do it? – android developer Dec 02 '15 at 11:04

0 Answers0