This is Sonic, 0.1 originally built by members of The Philadelphia Game Lab.
Sonic is a library of C++ routines for performing real-time binaural audio processing on mobile devices. The current version supports only iOS devices.
include/
Header files for the source code.
source/
Source code for library itself. Function definitions of functions declared in the include/ directory are included here.
iOS/
Files and functions necessary to interface with iOS system calls.
MIT\_HRTF\_Library/
Files and functions for audio processing. This code is available under the MIT license as specified here.
soundFiles/
Sound files for testing. File are arranged in subdirectories by file type. Files are named with the convention <bit-depth>-<sample-rate>-<description>.<extension>
.
Documentation for Sonic was generated using Doxygen, and can be found here. The Doxygen-style documentation was in turn generated using the doxit.py
script included in testgen 0.11.
Officially Sonic is only compatible with 16-bit WAV LPCM @ 44.1kHz, though converting other formats to this is very easy using Sox, the Sound eXchange library:
$> sox -b 16 .wav rate 44100 dither -s
Work is currently being done on interfacing the Sonic library with a config file where parameters like bit-depth and sampling rate can be adjusted, making Sonic compatible with other formats without need for file conversion.
SonicDemo: A starting point for your Sonic app.
SteerAudio: Use gyroscope input to shape sounds
Knobs: Turn knobs to move an audio object around in 3D space.
We are currently working on compiling Sonic into a static library. In the meantime, if you would like to import the source into your iOS project, either fork SonicDemo or consult the Sonic Setup Guide for manual setup instructions.
If you would like to make changes to the Sonic library, first fork it. Then you can either build your own testing application around that fork using the setup instructions or use one of our existing demo apps. If you prefer to do the latter, first fork the demo app of your choice then change its Sonic submodule to point to your Sonic fork rather than to the master copy:
$> git clone --recursive https://github.com/<path/to/demoapp/fork>.git
$> cd YourDemoAppFork
YourDemoAppFork$> vim .gitmodules
# replace https://github.com/PhiladelphiaGameLab/Sonic.git with https://github.com/path/to/your/sonic/fork.git
YourDemoAppFork$> git submodule sync
YourDemoAppFork$> cd Sonic
YourDemoAppFork/Sonic$> git checkout master
YourDemoAppFork/Sonic$> git pull --rebase origin master
Now you can modify both the Sonic library and the application it's included in and push changes to their respective forks. Note the difference between your demo app fork--which is your editable copy of one of the Sonic demo apps--and your Sonic fork--which is your editable copy of the Sonic library itself. Also be aware that forks, unlike branching, don't stay in sync with their upstream repos (in this case the master Sonic repo) unless you explicitly pull changes from them.
For more help on working with git submodules, consult the submodule documentation.
For more information, check out the Sonic project webpage.