I have generated a synthetic 'concert pitch A' tone from sinewaves.
It plays properly on OS X player, and on my Android device.
Now I record myself singing a 'concert pitch A' into the microphone as a MONO .WAV -- foo.wav.
In Unity I add foo.wav to my resources, making sure to turn off "is 3D sound" in the settings panel.
I then create a script that loads it into an audioclip and extracts the contents into a float buffer:
AudioSettings.outputSampleRate = 44100; // just to be safe AudioClip phonemeClip = Resources.Load( filename ) as AudioClip; float  phonemeBuf = new float[ phonemeClip.samples * phonemeClip.channels ]; phonemeClip.GetData( phonemeBuf, 0 );
I then add this sound to my synthetic tone, 30000 samples in (so nearly 1 second):
float PHONEME_VOL = 0.3f; int OFFSET = 30000; for(int i=0; i<phonemeBuf.Length; i++) if( OFFSET+i < buf.Length ) buf[OFFSET+i] += phonemeBuf[i] * PHONEME_VOL;
On OSX player this works perfectly.
However on my android device the original synthetic tone plays correctly whereas the added foo.wav appears to be exactly an octave low.
What might be causing this?
I suspect it may be converting the clip into a stereo clip, with 0 for the right channel. That would interpolate the resultant float buffer with zeros, which would certainly take it down octave.
But I can't see how to address this problem.