I created a sample audio player application in android. In my application I used Play, Pause and Stop functions. Now I wish to add Loop functionality in my application. i.e., when I click the Loop button, recently played audio will play continuously, when I click Stop button the audio file will be stop. I go through the android developer site, I got a function setLooping(boolean). I set this my media player nothing will happen, how can I use this, in my code I used like this,
MediaPlayer mPlayer= new MediaPlayer();
mPlayer.setLooping(false);
you are setting the setLooping to false ,if you want to be repeted you must set it to true .You want it to be playing again and again right?
Use: