Getting Ready for Sounds

Before you can explore sounds in your Android games, you need to find some to use. Android supports a variety of sound formats, the most popular of which are .mp3, .wav, and .mid. Personally, I prefer to use an MP3 file for small sound effects, like explosions, and MIDI files for musical scores. This is a common practice to keep file sizes to a minimum while also using the popular file choices. If you have sounds in other file formats, you can visit Android’s list of accepted media formats here: http://developer.android.com/guide/appendix/media-formats.html.

Of special interest to some who have a passion for audio and music is the Free Lossless Audio Codec (FLAC) support that Android provides. FLAC is a format that is ...

Get Beginning Android Tablet Games Programming now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.