# Using MediaPlayer or SoundPool

**URL:** <https://discourse.processing.org/t/using-mediaplayer-or-soundpool/1080>\
**Category:** Processing for Android\
**Created:** [June 19, 2018, 2:12pm UTC](https://discourse.processing.org/t/using-mediaplayer-or-soundpool/1080 "2018-06-19T14:12:28Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![kfrajer](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/kfrajer/32/196_2.png) [@kfrajer](https://discourse.processing.org/u/kfrajer)\
**Post date:** [June 19, 2018, 11:12pm UTC](https://discourse.processing.org/t/using-mediaplayer-or-soundpool/1080/2 "2018-06-19T23:12:20Z")

</div>

There are a couple of strategies as far as I understand, which I presented in a previous post of yours: [Tracking high score for android](https://discourse.processing.org/t/tracking-high-score-for-android/678/3)

If you place your mp3 file in the data folder, you should be able to do this:

`mp.setDataSource(dataPath("youraudiofile.mp3"));`

You can also use the assets manager. Or explore examples working with external storage options.

Here I have an example playing sound tested on Android: [A sound play exemplar please?](https://discourse.processing.org/t/a-sound-play-exemplar-please/416/5)

Notice that there might be some changes in Android Mode version 4.0.2 that Andres have implemented, as discussed [here])([https://github.com/processing/processing-android/issues/450#issuecomment-398517160](https://github.com/processing/processing-android/issues/450#issuecomment-398517160)).

Kf

---

_[View the full topic](https://discourse.processing.org/t/using-mediaplayer-or-soundpool/1080)._
