3D Audio on Android

I read that jME is being ported to Android, and I was wandering if any research has been done yet about simulating 3D audio on Android (for when a player has stereo earphones, for example).  So far, Android audio seems extremely high-level and very limited in its capability, and neither JavaSound nor OpenAL are implemented.



3D sound is definitely possible on Android - there are apps out there that do it (the vOICe overlay, for example).  The three basic capabilities needed are playback of PCM data and controlling gain and pan.  Mixing would also be nice, although it should be possible to develop a software synthesis library from scratch to do that if needed.



Has anyone here seen any information on how to do one or more of these things?

jME3 android support is low priority at the moment. But 3D sound is definitely doable in Android.



Check the AudioTrack class, you simply create an instance, feed it with audio and set the panning with setStereoVolume. Now you just need to convert the 3D audio sources into left and right stereo volume and you have 3D sound in Android.

Thanks, that class is exactly what I was looking for.  The "write" method should take care of playing PCM data, and the "setStereoVolume" method should take care of both the gain and pan requirements.  I've already done something similar with JavaSound before, so this shouldn't be much different.



I'm thinking of making an Android port of my SoundSystem library if I can ever find the time.  If I do, I'll post the source code here for reference when jME on Android is ready for it's own 3D sound capability.