Answer the question
In order to leave comments, you need to log in
How to play m3u8 broadcast on android java?
I organized the playback of the live broadcast like this:
private void setupVideoView() {
// Make sure to use the correct VideoView import
videoView = findViewById(R.id.video_view);
videoView.setOnPreparedListener(new MediaPlayer.OnPreparedListener() {
@Override
public void onPrepared(MediaPlayer mp) {
videoView.start();
}
});
//For now we just picked an arbitrary item to play
videoView.setVideoURI(Uri.parse(stream_key));
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question