[Icecast] Delay playing some streams on Android
M M
mh747 at outlook.com
Tue Sep 29 21:13:01 UTC 2015
I'm writing an Android app to play streams. I use the standard Android "MediaPlayer" library to play streams. I've noticed that some streams start playing without much delay (MPR), but others take quite a while to start (WFMU). The only thing changing in my code is the URI of the Icecast mountpoint. My test device is a Nexus 5 running Android 5.1.1.
http://current.stream.publicradio.org/kcmp.mp3 starts playing in about 2 seconds. It's a 128 kbps stream from Minnesota Public Radio.
http://stream0.wfmu.org/freeform-128k starts playing in about 9 seconds. It's a 128 kbps stream from WFMU.
The problem gets worse as the bitrate goes down. 32 kbps streams take quite a while to start.
I don't notice this problem in iOS code I've written. I also don't notice it in VLC.
You can view the headers with:
curl -s -D - http://current.stream.publicradio.org/kcmp.mp3 -o /dev/null
StackOverflow has several posts about this. For example: http://stackoverflow.com/questions/6582908/why-does-it-take-so-long-for-androids-mediaplayer-to-prepare-some-live-streams.
Any idea what's going on?
More information about the Icecast
mailing list