Greetings, tl;dr - I'm looking for sources to an Android Icecast client written in Java. long summary: I maintain an open source Android app (WREK Online) that plays the live mp3 stream from the station's Icecast server. Using the built in MediaPlayer class that is part of the Android SDK works OK. As a developer, I just give it the streaming URL of the Icecast server, hook up a few callbacks, and it plays just fine. But this class has its limitations and a few bugs. The biggest limitation of Android's MediaPlayer class is that it can't pull down the metadata from the Icecast server. It doesn't pass allow an option for the developer to pass up an Ice-MetaData header for the specified URL. And even if you could, it likely wouldn't be able to parse out the inline metadata within the returned HTTP byte stream (as indicated by the presence of an icy-metaint header). So therefore, my app can't show the current artist and song title on the screen very easily. An alternative option is to continuously make an http polling request for the "status.xsl" page on the server and parse this information out. But polling isn't an ideal solution. I am considering going full on an writing my own replacement for MediaPlayer. This would mean handling my own HTTP streaming, my own MP3 frame parser, additional code to extract out the metadata from the stream bytes, calling into Android's MediaCodec APIs to convert to PCM, and ultimately into an AudioTrack instance. All of which I am comfortable doing. However, this will likely take me a better part of a week to get working with lots of testing and bug fixing. Is there an open-source solution I could potentially leverage? I know there are few Linux projects written in C/C++ that have been ported to the Android NDK, but I'd prefer an Android Java solution. I've Google'd around, but couldn't find anything definitive. Suggestions? Thanks,jSelbie -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.xiph.org/pipermail/icecast-dev/attachments/20140619/daf470c8/attachment.htm
marcin at saepia.net
2014-Jun-20 05:56 UTC
[Icecast-dev] Android Java source for icecast streaming
Rewriting everything is not necessary. I have a working solution for metadata extraction, that still relies on MediaPlayer, I can license it for a fair price. I am using it here: http://radiofonia.net/android Marcin 20 cze 2014 06:59 "John Selbie" <jselbie at hotmail.com> napisa?(a):> Greetings, > > tl;dr - I'm looking for sources to an Android Icecast client written in > Java. > > long summary: > > I maintain an open source Android app (WREK Online) that plays the live > mp3 stream from the station's Icecast server. > > Using the built in MediaPlayer class that is part of the Android SDK works > OK. As a developer, I just give it the streaming URL of the Icecast server, > hook up a few callbacks, and it plays just fine. But this class has its > limitations and a few bugs. > > The biggest limitation of Android's MediaPlayer class is that it can't > pull down the metadata from the Icecast server. It doesn't pass allow an > option for the developer to pass up an Ice-MetaData header for the > specified URL. And even if you could, it likely wouldn't be able to parse > out the inline metadata within the returned HTTP byte stream (as indicated > by the presence of an icy-metaint header). > > So therefore, my app can't show the current artist and song title on the > screen very easily. An alternative option is to continuously make an http > polling request for the "status.xsl" page on the server and parse this > information out. But polling isn't an ideal solution. > > I am considering going full on an writing my own replacement for > MediaPlayer. This would mean handling my own HTTP streaming, my own MP3 > frame parser, additional code to extract out the metadata from the stream > bytes, calling into Android's MediaCodec APIs to convert to PCM, and > ultimately into an AudioTrack instance. All of which I am comfortable > doing. However, this will likely take me a better part of a week to get > working with lots of testing and bug fixing. > > Is there an open-source solution I could potentially leverage? I know > there are few Linux projects written in C/C++ that have been ported to the > Android NDK, but I'd prefer an Android Java solution. I've Google'd > around, but couldn't find anything definitive. > > Suggestions? > > Thanks, > jSelbie > > > > > _______________________________________________ > Icecast-dev mailing list > Icecast-dev at xiph.org > http://lists.xiph.org/mailman/listinfo/icecast-dev > >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.xiph.org/pipermail/icecast-dev/attachments/20140620/828401b5/attachment.htm
Klaas Jan Wierenga
2014-Jun-20 07:58 UTC
[Icecast-dev] Android Java source for icecast streaming
Hi John, We have evaluated and used RadioStreamsSDK (http://www.binpress.com/app/radiostreams-sdk-for-android/964). Just another option. Regards, KJ Op 20 jun. 2014, om 07:56 heeft marcin at saepia.net het volgende geschreven:> Rewriting everything is not necessary. I have a working solution for metadata extraction, that still relies on MediaPlayer, I can license it for a fair price. > > I am using it here: http://radiofonia.net/android > > Marcin > > 20 cze 2014 06:59 "John Selbie" <jselbie at hotmail.com> napisa?(a): > Greetings, > > tl;dr - I'm looking for sources to an Android Icecast client written in Java. > > long summary: > > I maintain an open source Android app (WREK Online) that plays the live mp3 stream from the station's Icecast server. > > Using the built in MediaPlayer class that is part of the Android SDK works OK. As a developer, I just give it the streaming URL of the Icecast server, hook up a few callbacks, and it plays just fine. But this class has its limitations and a few bugs. > > The biggest limitation of Android's MediaPlayer class is that it can't pull down the metadata from the Icecast server. It doesn't pass allow an option for the developer to pass up an Ice-MetaData header for the specified URL. And even if you could, it likely wouldn't be able to parse out the inline metadata within the returned HTTP byte stream (as indicated by the presence of an icy-metaint header). > > So therefore, my app can't show the current artist and song title on the screen very easily. An alternative option is to continuously make an http polling request for the "status.xsl" page on the server and parse this information out. But polling isn't an ideal solution. > > I am considering going full on an writing my own replacement for MediaPlayer. This would mean handling my own HTTP streaming, my own MP3 frame parser, additional code to extract out the metadata from the stream bytes, calling into Android's MediaCodec APIs to convert to PCM, and ultimately into an AudioTrack instance. All of which I am comfortable doing. However, this will likely take me a better part of a week to get working with lots of testing and bug fixing. > > Is there an open-source solution I could potentially leverage? I know there are few Linux projects written in C/C++ that have been ported to the Android NDK, but I'd prefer an Android Java solution. I've Google'd around, but couldn't find anything definitive. > > Suggestions? > > Thanks, > jSelbie > > > > > _______________________________________________ > Icecast-dev mailing list > Icecast-dev at xiph.org > http://lists.xiph.org/mailman/listinfo/icecast-dev > > _______________________________________________ > Icecast-dev mailing list > Icecast-dev at xiph.org > http://lists.xiph.org/mailman/listinfo/icecast-dev-------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.xiph.org/pipermail/icecast-dev/attachments/20140620/350ca8cf/attachment.htm
Luca Cireddu
2014-Jun-20 08:36 UTC
[Icecast-dev] Android Java source for icecast streaming
Hi jSelbie, try to have a look to https://code.google.com/p/unicaradio-apps/. Our developer created an app that obtain metadata by splitting icecast stream and rebuilding it without metadata. 2014-06-20 6:59 GMT+02:00 John Selbie <jselbie at hotmail.com>:> Greetings, > > tl;dr - I'm looking for sources to an Android Icecast client written in > Java. > > long summary: > > I maintain an open source Android app (WREK Online) that plays the live > mp3 stream from the station's Icecast server. > > Using the built in MediaPlayer class that is part of the Android SDK works > OK. As a developer, I just give it the streaming URL of the Icecast server, > hook up a few callbacks, and it plays just fine. But this class has its > limitations and a few bugs. > > The biggest limitation of Android's MediaPlayer class is that it can't > pull down the metadata from the Icecast server. It doesn't pass allow an > option for the developer to pass up an Ice-MetaData header for the > specified URL. And even if you could, it likely wouldn't be able to parse > out the inline metadata within the returned HTTP byte stream (as indicated > by the presence of an icy-metaint header). > > So therefore, my app can't show the current artist and song title on the > screen very easily. An alternative option is to continuously make an http > polling request for the "status.xsl" page on the server and parse this > information out. But polling isn't an ideal solution. > > I am considering going full on an writing my own replacement for > MediaPlayer. This would mean handling my own HTTP streaming, my own MP3 > frame parser, additional code to extract out the metadata from the stream > bytes, calling into Android's MediaCodec APIs to convert to PCM, and > ultimately into an AudioTrack instance. All of which I am comfortable > doing. However, this will likely take me a better part of a week to get > working with lots of testing and bug fixing. > > Is there an open-source solution I could potentially leverage? I know > there are few Linux projects written in C/C++ that have been ported to the > Android NDK, but I'd prefer an Android Java solution. I've Google'd > around, but couldn't find anything definitive. > > Suggestions? > > Thanks, > jSelbie > > > > > _______________________________________________ > Icecast-dev mailing list > Icecast-dev at xiph.org > http://lists.xiph.org/mailman/listinfo/icecast-dev > >-- Luca Cireddu sardylan at gmail.com http://www.lucacireddu.it -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.xiph.org/pipermail/icecast-dev/attachments/20140620/01a21ed6/attachment-0001.htm
Thank you. That's a nice looking radio app. On that link below, I only see links to download pre-compiled APK files (apps). Are there links to the actual source code available? Date: Fri, 20 Jun 2014 10:36:58 +0200 From: sardylan at gmail.com To: icecast-dev at xiph.org Subject: Re: [Icecast-dev] Android Java source for icecast streaming Hi jSelbie, try to have a look to https://code.google.com/p/unicaradio-apps/.Our developer created an app that obtain metadata by splitting icecast stream and rebuilding it without metadata. 2014-06-20 6:59 GMT+02:00 John Selbie <jselbie at hotmail.com>: Greetings, tl;dr - I'm looking for sources to an Android Icecast client written in Java. long summary: I maintain an open source Android app (WREK Online) that plays the live mp3 stream from the station's Icecast server. Using the built in MediaPlayer class that is part of the Android SDK works OK. As a developer, I just give it the streaming URL of the Icecast server, hook up a few callbacks, and it plays just fine. But this class has its limitations and a few bugs. The biggest limitation of Android's MediaPlayer class is that it can't pull down the metadata from the Icecast server. It doesn't pass allow an option for the developer to pass up an Ice-MetaData header for the specified URL. And even if you could, it likely wouldn't be able to parse out the inline metadata within the returned HTTP byte stream (as indicated by the presence of an icy-metaint header). So therefore, my app can't show the current artist and song title on the screen very easily. An alternative option is to continuously make an http polling request for the "status.xsl" page on the server and parse this information out. But polling isn't an ideal solution. I am considering going full on an writing my own replacement for MediaPlayer. This would mean handling my own HTTP streaming, my own MP3 frame parser, additional code to extract out the metadata from the stream bytes, calling into Android's MediaCodec APIs to convert to PCM, and ultimately into an AudioTrack instance. All of which I am comfortable doing. However, this will likely take me a better part of a week to get working with lots of testing and bug fixing. Is there an open-source solution I could potentially leverage? I know there are few Linux projects written in C/C++ that have been ported to the Android NDK, but I'd prefer an Android Java solution. I've Google'd around, but couldn't find anything definitive. Suggestions? Thanks,jSelbie _______________________________________________ Icecast-dev mailing list Icecast-dev at xiph.org http://lists.xiph.org/mailman/listinfo/icecast-dev -- Luca Cireddu sardylan at gmail.com http://www.lucacireddu.it _______________________________________________ Icecast-dev mailing list Icecast-dev at xiph.org http://lists.xiph.org/mailman/listinfo/icecast-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.xiph.org/pipermail/icecast-dev/attachments/20140620/64b754e7/attachment.htm