Using sound generators

So, we have learned about direct access to the audio device in Libgdx, and we know now know to write audio samples to it. Sure enough, we could now (try to) write our own sound generator class from here and feed one of Libgdx's audio device instances with the resulting audio samples. However, audio programming is beyond the scope of this book, and it is also a very advanced topic even for seasoned programmers.

A viable solution to get hold of some nice sound effects is to use one of the existing sound generators which are free and open source. One of these sound generators is called sfxr, which was originally developed by Tomas "DrPetter" Pettersson in 2007. Over time, several sfxr variants have emerged, such as bfxr, cfxr, ...

Get Learning Libgdx Game Development 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.