stuttered Audio

All your problems with Audio, Video and Images.

stuttered Audio

Postby ikerib » Mon Feb 28, 2011 1:39 pm

Hi!

I have a button when I clicked in it shows me an slide with a picture and plays an audio from my sd card with this code:

Code: Select all
public void buttonClickHandler(View v) {
    this.onClickNextDiapositiva();
    Diapositiva diapo1 = this.getDiapoActual();
    try {
        if (diapo1.tieneSonido()) {
           String sndPath = ZIP_SND_PATH + diapo1.getSonido().getNombre();
           InputStream isSonido = this.getTutorFile().getFile(sndPath);

           this.audioPlayer = new StreamingMediaPlayer(this);
           this.audioPlayer.startStreaming(isSonido);   
        }   else if (diapo1.tieneVideo()) {
           if (!diapo1.tieneImagen()) {
           String imgPath = ZIP_FONDOS_PATH + "fondo_video.png";
           cargarImagen(imgPath);
           }
        }
    } catch (Throwable ex) {
       Log.e("mostrarDiapositiva", ex.getMessage());
       Toast
       .makeText(this, "Error: " + ex.getMessage(), Toast.LENGTH_SHORT)
       .show();
    }
    break;
}


the fact is that the code works, the slide is changed and de audio played but it starts and when less than one second is played it started again, it´s like if it was stuttered.

Any idea why is this happening? thanks too much
ikerib
Freshman
Freshman
 
Posts: 2
Joined: Fri Feb 25, 2011 2:22 pm

Top

Return to Multimedia Problems

Who is online

Users browsing this forum: Exabot [Bot], Google Feedfetcher and 10 guests