Working with sound assets

Sound can be used for various things in an Android application. From streaming music to acting as notifications or even acting as background music in a game.

Here’s some examples on how to play audio.

Examples

Playing audio from the asset folder.

This video also explains how to play a local audio file.

You can also stream audio from online sources, if the user is connected to the internet.


RAW CONTENT URL