views:

1628

answers:

1

I want to create an Android application that is a client for an Internet radio station. And I want it look native to Android? But im confused with Android API logic and documentation. What i've got is that I need MediaPlayer and MediaController classes. Am I right, and is there any good example of AUDIO player for Android?

Especially, I'm very interested how to use MediaPlayer and MediaController classes together.

UPD:

Finally I've got the code, that does exactly what I want:

Intent i = new Intent(Intent.ACTION_VIEW);

Uri u = Uri.parse(%file_uri%));

i.setData(u);

startActivity(i);

+2  A: 

Hi,

you can look at those links :

http://blog.pocketjourney.com/2008/04/04/tutorial-custom-media-streaming-for-androids-mediaplayer/

http://www.helloandroid.com/tutorials/musicdroid-audio-player-part-i

Hope it will help.

[EDIT]

You have also some example on the official android developer website :

http://developer.android.com/guide/topics/media/index.html

Michaël
Got the solution