How to stream video with Android Emulator

This is a discussion on How to stream video with Android Emulator within the Droid Development forums, part of the Droid Hacking category; Nice to meet you all!!! I'm still new to Android. I try to write a simple program to stream video but the returned message is ...

+ Reply to Thread
Results 1 to 1 of 1

Thread: How to stream video with Android Emulator

  1. Droid Newbie
    ngubk's Avatar
    Member #
    230901
    Join Date
    Oct 2011
    Posts
    1
    Phone
    Enter Current Phone Model Here
    #1

    How to stream video with Android Emulator

    Nice to meet you all!!! I'm still new to Android. I try to write a simple program to stream video but the returned message is always::Sorry, this video cannot be played". Here's the code:
    Code:
    public class Video_testActivity extends Activity {    public static VideoView mVideoView;
        public static MediaController mediaController;
    
        public static String path_uri = "rtsp://localhost:554/sample_100kbit.mp4";
    
        @Override
        public void onCreate(Bundle savedInstanceState) {
            super.onCreate(savedInstanceState);
            setContentView(R.layout.main);
            mVideoView = (VideoView) findViewById(R.id.VideoView);
    
            mediaController = new MediaController(this);
            mediaController.setAnchorView(mVideoView);
    
             Uri video = Uri.parse(path_uri);
      
             mVideoView.setMediaController(mediaController);
             mVideoView.setVideoURI(video);
             //videoView.setVideoPath(path);
             mVideoView.start();
        }
    }
    "rtsp://localhost:554/sample_100kbit.mp4" is the address of the streamed video. I can view it just fine using vlc
    Last edited by ngubk; 10-22-2011 at 10:25 AM.
  2. Sponsor
    DF Advertising
    Join Date
    Nov 2008
    Location
    DroidForums.net
     
     
     
     

Sponsors

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Similar Threads

  1. Replies: 3
    Last Post: 02-15-2012, 10:07 PM
  2. stream video to X
    By wgormley in forum Droid X General Discussions
    Replies: 2
    Last Post: 04-10-2011, 10:32 PM
  3. Video Stream App?
    By xxpigxx in forum Droid Applications
    Replies: 0
    Last Post: 02-13-2011, 09:55 PM
  4. How to stream video
    By ppppowerbook in forum Droid Audio / Video
    Replies: 8
    Last Post: 07-28-2010, 07:51 PM
  5. is there an app to stream video from network
    By cnmsales in forum Droid Applications
    Replies: 8
    Last Post: 05-30-2010, 03:04 AM

Search tags for this page

android how to stream video
,
how to stream movies to droid
,

how to stream video on android

,

how to stream video to android

,
how to stream video with mediacontroller in android code
,

how to stream videos in android/

,

how to stream videos on android

,
rtsp android x2
,
rtsp on droid razr
,

stream a video on network android

,

stream video on android

,
streaming to emulator android
,
streaming url rtsp on emulator android
,
video in android emulator
,
videoview emulator
Click on a term to search our site for related topics.