Search code examples
objective-ciosxcodeaudiomp3

audio control in iOS


Is it possible to control the playback of an mp3 file in iOS so that when listening on headphones you can change the side at which the sound is heard.

e.g. if your playing a stereo mp3 file where a person speaking is coming out the left headphone can you then switch it round to come from the right side.

the idea is to change the side the sound is coming from without needing 2 mp3 files that are setup for left or right.

if it is possible where is the best place to start.

Thanks


Solution

  • You can control where the playback occurs using OpenAL. It's not the easiest framework to get into, but Apple do supply a demo project that should get you started:

    https://developer.apple.com/library/ios/#samplecode/oalTouch/Introduction/Intro.html