The Cupcake branch has provisions for streaming linear PCM audio in and out of Java.
But before everyone gets too excited, please remember that it takes time for code in a stabilization branch to be deployed on a device. There are a series of release candidates, terminal acceptance cycles on handset(s), and then manufacturing and/or OTA cycles. It may be months before you see this feature on an actual device. On Dec 23, 10:44 am, "Aldo Neto" <tumo...@gmail.com> wrote: > Thanks! > I believe that Android team will add support for streaming sometime in the > future, is that right? > > On Tue, Dec 23, 2008 at 4:37 PM, Dave Sparks <davidspa...@android.com>wrote: > > > > > The MediaPlayer doesn't support streaming at all. You can get away > > with a "pseudo-streamed" MP3 because the MP3 format was intended to be > > broadcast and the MP3 parser is a bit more forgiving about it than the > > other parsers. > > > On Dec 23, 4:21 am, "Aldo Neto" <tumo...@gmail.com> wrote: > > > Hi, > > > I developed a quite simple code for audio streaming with MediaPlayer > > > (please see code below). I tested it with an MP3 file and it worked > > > perfectly. However, when I tested the same code with a WAV audio, the > > > MediaPlayer was unable to stream the audio properly. > > > > I had to build a StreamPlayer based onhttp:// > > blog.pocketjourney.com/2008/04/04/tutorial-custom-media-stream... > > > > I don't know if this a known issue that I'm not aware, but does > > anybody > > > knows why the code below wouldn't work with WAV files? Does MediaPlayer > > > library supports WAV streaming? > > > > Thanks > > > > final ProgressBar progressBar = (ProgressBar) > > > findViewById(R.id.progress_bar); > > > player = new MediaPlayer(); > > > player.setDataSource(path); > > > player.setAudioStreamType(AudioManager.STREAM_MUSIC); > > > player.prepareAsync(); > > > player.setOnPreparedListener(new OnPreparedListener(){ > > > > @Override > > > public void onPrepared(MediaPlayer mp) > > > { > > > //Preparation finished. Start playing voicemail > > > player.start(); > > > > //Update primary progress on Progress bar > > > startPlayProgressUpdater(); > > > } > > > }); > > > > player.setOnBufferingUpdateListener(new OnBufferingUpdateListener() > > > { > > > > @Override > > > public void onBufferingUpdate(MediaPlayer mp, int percent) > > > { > > > //Update secondary progress on Progress bar > > > progressBar.setSecondaryProgress(percent); > > > } > > > }); --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---