How to get RTSP Links Android

Udaykiran picture Udaykiran · Jun 29, 2011 · Viewed 16.4k times · Source

Am having you-tube links like http://www.youtube.com/v/YR71GnQ4CU4?f=videos&app=youtube_gdata , then how to convert it to RTSP format to play in VideoView.

Am searching gdata api with this: http://gdata.youtube.com/feeds/api/videos?&max-results=20&v=2&format=1&q="+ URLEncoder.encode(activity.criteria) but i cant find how to get related RTSP url.

Answer

Udaykiran picture Udaykiran · Jun 29, 2011

I got my answer ..thanx to this

Element rsp = (Element)entry.getElementsByTagName("media:content").item(1);

                              String anotherurl=rsp.getAttribute("url");

In gdata api only we are getting this type of links : rtsp://v3.cache7.c.youtube.com/CiILENy73wIaGQlOCTh0GvUeYRMYDSANFEgGUgZ2aWRlb3MM/0/0/0/video.3gp

These are playing in VideoView.