I have developed a small app that can record and play small videos (upto 10 secs). The app captures video at 6 Mbps. To ensure faster video playback, I'm trying to implement HLS (http live streaming). But I have noticed that the app always picks up the stream with lowest bitrate first and only switches to the best available stream (based on network bandwidth) only after 10 secs.
I have tested different media players like android media player, exoplayer etc., but the behaviour is consistent. The video changes streams only after exactly 10 seconds. Is this the default implementation of hls in android? or Am I missing something? The m3u8 I used to test is http://devimages.apple.com/iphone/samples/bipbop/bipbopall.m3u8
localUrl = "http://devimages.apple.com/iphone/samples/bipbop/bipbopall.m3u8";
vidView.setVideoPath(localUrl);
Log.i("GenericRequest", "VideoUrl " + localUrl);
vidView.setOnPreparedListener(new MediaPlayer.OnPreparedListener() {
@Override
public void onPrepared(MediaPlayer mp) {
vidView.start();
}
});