In my application I have a videoview and I want to play youtube videos in that.For that I tried lots of methods like
VideoView mVideoView = new VideoView(this);
setContentView(mVideoView);
mVideoView.setVideoURI(Uri.parse("rtsp://v3.cache7.c.youtube.com/CiILENy73wIaGQlOCTh0GvUeYRMYDSANFEgGUgZ2aWRlb3MM/0/0/0/video.3gp"));
mVideoView.start();
For this I am getting
08-13 12:33:07.443: D/MediaPlayer(618): Couldn't open file on client side, trying server side
08-13 12:33:09.003: E/MediaPlayer(618): error (1, -2147483648)
08-13 12:33:09.003: E/MediaPlayer(618): Error (1,-2147483648)
Then I tried
VideoView mVideoView = new VideoView(this);
setContentView(mVideoView);
mVideoView.setVideoURI(Uri.parse("vnd.youtube:GDD0Brw-udk"));
mVideoView.start();
Here also I am getting the same error.
And
startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("http://www.youtube.com/watch?v=GDD0Brw-udk&feature=youtube_gdata_player")));
This leaves my application, and starts the mobile youtube where I have no control.
Another method I used is
Intent lVideoIntent = new Intent(null, Uri.parse("http://www.youtube.com/get_video_info?&video_id=GDD0Brw-udk")
, this, IntroVideoActivity.class);
startActivity(lVideoIntent);
This is also not working for me..
What should I do..Anyone help me please..Thanx in advance